Let me address the "printing array reference" part of your message, as I could not make sense of the remainder yet. "$dub_key => $dub_values\n" could be made to work by using:
or, with a Perl data dumping module, like Data::Dump:"$dub_key => ", join(",",@$dub_values), "\n" # will print # dubhpr01.hpux => name,uid,gid,comments
(In the examples above, $dub_key = 'dubhpr01.hpux' and $dub_values = [qw(name uid gid comments)].)use Data::Dump; # somewhere before in the code # then "$dub_key => ", Data:Dump::dump($dub_values), "\n" # will print # dubhpr01.hpux => ["name", "uid", "gid", "comments"]
In reply to Re: printing array reference and storing this data in a hash.
by ferreira
in thread printing array reference and storing this data in a hash.
by mikejones
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |