Beefy Boxes and Bandwidth Generously Provided by pair Networks
Just another Perl shrine
 
PerlMonks  

Re^3: golf: shortest way to parse a pipe delimited file

by bageler (Hermit)
on Nov 10, 2005 at 19:38 UTC ( #507513=note: print w/replies, xml ) Need Help??


in reply to Re^2: golf: shortest way to parse a pipe delimited file
in thread golf: shortest way to parse a pipe delimited file

this fails by giving an empty hash entry.
$VAR1 = { '' => [], 'aaa' => [ 'bbb', 'ccc' ], 'foo' => [ 'bar', 'baz' ] };

Replies are listed 'Best First'.
Re^4: golf: shortest way to parse a pipe delimited file
by tilly (Archbishop) on Nov 11, 2005 at 05:45 UTC
    It doesn't fail for me with Perl 5.8.7.

    My best guess is that your input had a blank line in it at the start or the end. That blank line would (legitimately from the spec) result in the output that you saw.

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others studying the Monastery: (6)
As of 2022-10-06 11:45 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    My preferred way to holiday/vacation is:











    Results (26 votes). Check out past polls.

    Notices?