Bryan R Harris wrote: > > > This should do what you want: > > > > use File::Find; > > my %dirs; > > find( sub { push @{$dirs{$File::Find::dir}}, "$_\n" unless /^\.\.?$/ }, > > @ARGV ); > > > > for my $dir ( keys %dirs ) { > > open OFILE, "> $dir/index.txt" or warn "Cannot open $dir/index.txt: > > $!"; > > print OFILE @{$dirs{$dir}}; > > close OFILE; > > } > > > > __END__ > > Uh, I may be on the wrong list... Is there a pre-beginners list? =) > > What does this notation mean? > > @{$dirs{$dir}} > > Thanks for the replies, the two were perfect -- what I was doing wrong with > my code, and what I *should* have been doing. This list is great...
That is a Hash of Arrays and is described in the perldsc.pod document. perldoc perldsc John -- use Perl; program fulfillment -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]