Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl-Sensitive Sunglasses
 
PerlMonks  

Re: split line and populate hash shortcut ?

by revdiablo (Prior)
on Feb 15, 2006 at 17:16 UTC ( [id://530450]=note: print w/replies, xml ) Need Help??


in reply to split line and populate hash shortcut ?

Another possible solution, sticking with split but using map:

my %config = map { chomp; /^#/ ? () : split /=/, $_, 2 } <IN>;

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others imbibing at the Monastery: (6)
As of 2024-04-19 08:02 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found