Beefy Boxes and Bandwidth Generously Provided by pair Networks
Come for the quick hacks, stay for the epiphanies.
 
PerlMonks  

Re^3: How to club different lines of program into one

by akho (Hermit)
on May 25, 2009 at 19:40 UTC ( [id://766091]=note: print w/replies, xml ) Need Help??


in reply to Re^2: How to club different lines of program into one
in thread How to club different lines of program into one

I was writing this on a machine without Perl, thus the syntax error and no testing; I also tried to be extra safe with context in the do. That scalar is not necessary.

Sorry for the confusion, if there was any.

As for the OP's intent: it is hard to understand it. But the title question was "How to club different lines of program into one", so I tried to do the same thing the OP's code is doing, but in less lines.

And I don't have an excuse for not testing my open except that I usually use autodie.

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others drinking their drinks and smoking their pipes about the Monastery: (2)
As of 2026-01-18 07:24 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    What's your view on AI coding assistants?





    Results (121 votes). Check out past polls.

    Notices?
    hippoepoptai's answer Re: how do I set a cookie and redirect was blessed by hippo!
    erzuuliAnonymous Monks are no longer allowed to use Super Search, due to an excessive use of this resource by robots.