http://qs321.pair.com?node_id=1028109

Bindo has asked for the wisdom of the Perl Monks concerning the following question:

Greetings good people! I just want to find all the directories containig only numbers and assign them to an array. For an instance I would want isolate the directories in a certain partition with this format "20130411". Not "2013.kjh" or "NN.201304", or "2013mmkk04". Following is what I tried but they returns not only what i want but the ones with letters

my @LOGDIR = <*>; foreach my $DIR(@LOGDIR) { if($DIR =~ m/([\d])/){ print "$DIR\n"; } }

Please can someone help. Many thanks in advance.

Bindo