PrincePerl has asked for the wisdom of the Perl Monks concerning the following question:
Hello, still new to perl and learning. I am dealing with references and
i wanted to have an Array reference of hash reference, but i keep getting nothing, but output like this: $VAR1 = [] when i use Data::Dumper
help
while(<INFILE>) { @off = split(/' '/,$_); %find = ("start" => $off[0], "stop" => $off[1]); my $hash_ref = \%find; my @official = []; push @official, $hash_ref; }
what am i doing wrong smart people.
Example file
1234 2345
1234 2345
3345 4456
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Array reference of hash references
by toolic (Bishop) on Oct 25, 2011 at 22:40 UTC | |
by PrincePerl (Novice) on Oct 25, 2011 at 22:58 UTC | |
by toolic (Bishop) on Oct 25, 2011 at 23:06 UTC | |
by PrincePerl (Novice) on Oct 25, 2011 at 23:10 UTC | |
by choroba (Cardinal) on Oct 26, 2011 at 07:30 UTC | |
|
Re: Array reference of hash references
by choroba (Cardinal) on Oct 25, 2011 at 22:41 UTC | |
|
Re: Array reference of hash references
by Util (Priest) on Oct 25, 2011 at 22:45 UTC |