my %hash; while(<>) { chop; my ( $k, $v ) = split /\s*\=\s*/; $hash{ $k } = defined ( $hash{ $k } ) ? $hash{$k } . ",$v" : $v; } while ( my ($k, $v ) = each %hash ) { print "$k = $v\n"; }
-M
Free your mind
In reply to Re: Converting Column Into Row
by Moron
in thread Converting Column Into Row
by sdslrn123
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |