Beefy Boxes and Bandwidth Generously Provided by pair Networks Frank
Problems? Is your data what you think it is?
 
PerlMonks  

Re: Mapping an array to a string

by Punitha (Priest)
on Jan 08, 2008 at 09:45 UTC ( #661042=note: print w/ replies, xml ) Need Help??


in reply to Mapping an array to a string

Hi chuck_norris

Did you want to do something like this

use strict; my @AoH = ( {'Lead'=>'fred','Friend'=>'barney'}, {'Lead'=>'george','Wife'=> 'jane','Son'=>'elroy'} ); my $string = \@AoH; for my $href ( @$string) { for my $role ( keys %$href ) { print "$role:$href->{$role}\n"; } }

Punitha


Comment on Re: Mapping an array to a string
Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://661042]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others meditating upon the Monastery: (6)
As of 2014-04-18 02:19 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    April first is:







    Results (460 votes), past polls