map { my $val = (split /\//, $_)[-1]; (my $key = $val) =~ s/\.txt//; $testhash1{$key} = $val } @teststr;
In reply to Re: hash assignment using map with multiple statements
by lamp
in thread hash assignment using map with multiple statements
by diomedea
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |