Ron Smith wrote:
The sulution that you and others gave to the previous problem worked
out fine. I thought I sent mail regarding that.

You may have done that; sorry if I was mistaken.

I didn't think that this was related to that problem; but, it is very
similar.

What I mean is that I believe it would make sense to combine them. For instance, consider this solution:

    my %HoA;
    for ( `dir /b/s` ) {
        push @{ $HoA{$1} }, $2 if /(.+)\\(\w+)\.\d+\.\w+$/;
    }

That gives you a hash with the directories as the keys, and references
to arrays with the basenames as the values. You can print it like this:

    for my $dir ( keys %HoA ) {
        print "$dir\n", join( "\n", @{ $HoA{$dir} } ), "\n\n";
    }

--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl

--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>




Reply via email to