The stupid question is the question not asked | |
PerlMonks |
Re^4: tree commandby Skeeve (Parson) |
on Oct 14, 2015 at 06:21 UTC ( [id://1144815]=note: print w/replies, xml ) | Need Help?? |
Okay. So would you mind telling me how I could filter out:
without iterating over the content of the directory and know in advance that the last 3 items in my list don't count? Example: I have in my list [ a b c d e ] where b, d and e are files, which I do not want to display, while a and c are the directories to show. How would I know that in advance? With my approach I filter b, d and e out, leaving me with just [ a c ]. So I know that after "c" there won't be any more files or directories to be displayed. How would you achieve this? s$$([},&%#}/&/]+}%&{})*;#$&&s&&$^X.($'^"%]=\&(|?*{% +.+=%;.#_}\&"^"-+%*).}%:##%}={~=~:.")&e&&s""`$''`"e
In Section
Cool Uses for Perl
|
|