in reply to Re: How do I put all sub-directories into an array?
in thread How do I put all sub-directories into an array?

grep { !/^\.\.?$/ && -d }
Careful: a directory called ..\n would fall through the cracks using $ as "end of string" match. You want grep { !/\A\.\.?\z/ && -d } But we don't have to use a regex for everything. grep { $_ ne '.' and $_ ne '..' and -d } ____________
Makeshifts last the longest.