Help for this page

Select Code to Download


  1. or download this
    my $dir = '/home/user1'; 
    my @files = glob("$dir/*");  # Get list of files 
    my @directories = grep { -d } @files;  # Use -d to get dirs
    
  2. or download this
    foreach my $directory (@directories) { 
      my @list = glob("$directory/*"); 
    }