#!/usr/bin/perl %hash=(); $key = "SingleKey"; @A = ("Many","Value"); foreach $v (@A){ chomp($v); #$hash{$key}=join("|",$hash{$key},$v); $hash{$key}="$hash{$key}"."$v"; } while (($K,$V)=each(%hash)){ print"$K->$V\n"; }

In reply to Re^2: multiple values for one key in hash by Anonymous Monk
in thread multiple values for one key in hash by sovixi

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post; it's "PerlMonks-approved HTML":