in reply to How to split "/"

Or, if you want to do it yourself, you could possibly try this:
my @paths = grep { -d} glob ("/home/temp/login/*");

Replies are listed 'Best First'.
Re^2: How to split "/"
by Anonymous Monk on Apr 28, 2014 at 08:34 UTC

    That lists the directories in the directory /home/temp/login/ (excluding ones starting with dots), but doesn't split the pathname into its components.

      Yes, you are alsolutely right. I wonder how I could misread so thoroughly the question or forget its content before I wrote my post. I should probably have had another coffee this morning before coming to the monastery.