Beefy Boxes and Bandwidth Generously Provided by pair Networks
We don't bite newbies here... much
 
PerlMonks  

Re: How can I skip an element in an array whilst reading...

by perlplexer (Hermit)
on Apr 06, 2002 at 19:06 UTC ( [id://157175]=note: print w/replies, xml ) Need Help??


in reply to How can I skip an element in an array whilst reading...

$|-- ? push @a, $_ : push @b, $_ for @in;

Replies are listed 'Best First'.
Re: Answer: How can I skip an element in an array whilst reading...
by belg4mit (Prior) on Apr 06, 2002 at 20:24 UTC
    Tsk tsk tsk, you could potentially leave $| in a state other than which you began ;-) That also relies upon it being unset initially in order for the first element of @in to end up @b

    --
    perl -pe "s/\b;([st])/'\1/mg"

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others taking refuge in the Monastery: (5)
As of 2024-03-28 22:10 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found