programming-examples/perl/Hash/Using references to a hash.pl
2019-11-15 12:59:38 +01:00

24 lines
417 B
Raku

#!/usr/bin/perl
%month = (
'01', 'Jan',
'02', 'Feb',
'03', 'Mar',
'04', 'Apr',
'05', 'May',
'06', 'Jun',
'07', 'Jul',
'08', 'Aug',
'09', 'Sep',
'10', 'Oct',
'11', 'Nov',
'12', 'Dec',
);
$pointer = \%month;
printf "\n Address of hash = $pointer\n ";
foreach $i (sort keys %$pointer) {
printf "$i is $$pointer{$i} \n";
}