Quicker way to print directories with a trailing slash if directory has children?

前端 未结 0 711
悲&欢浪女
悲&欢浪女 2020-11-21 05:43

I have a list of paths, some of which don\'t have any subdirectories, and some do, like so:

foo
bar/foo
baz/burr/ham

I want to return a list

相关标签:
回答
  • 消灭零回复
提交回复
热议问题