Logo

Programming-Idioms

History of Idiom 13 > diff from v1 to v2

Edit summary for version 2 by :

Version 1

2015-05-06, 21:04:48

Version 2

2015-07-31, 19:38:54

Idiom #13 Iterate over map keys and values

Print each key k i with its value x from an associative array mymap

Idiom #13 Iterate over map keys and values

Print each key k i with its value x from an associative array mymap

Code
while ( ($k,$v) = each %mymap) {
    print "Key=$k, Value=$v\n";
}