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

Re^3: P2P Golf: MoleSter

by Fletch (Chancellor)
on Dec 16, 2004 at 19:03 UTC ( #415430=note: print w/ replies, xml ) Need Help??


in reply to Re^2: P2P Golf: MoleSter
in thread P2P Golf: MoleSter

You actually cannot use pop instead of shift in the first line unless you rearrange the argument list order.

If there's no ordering dependencies between things (in this case &a and &i don't seem to depend on one being called before the others, and neither references $p) you can if you just reverse the order you pop rather than the argument order . . .

i(pop);$a=a(pop);$p=pop;...

Update: D'oh, missed the @ARGV later on. Never mind me.


Comment on Re^3: P2P Golf: MoleSter
Select or Download Code
Re^4: P2P Golf: MoleSter
by dragonchild (Archbishop) on Dec 16, 2004 at 19:05 UTC
    Except that @ARGV is used later on in the while() loop control statement.

    Being right, does not endow the right to be rude; politeness costs nothing.
    Being unknowing, is not the same as being stupid.
    Expressing a contrary opinion, whether to the individual or the group, is more often a sign of deeper thought than of cantankerous belligerence.
    Do not mistake your goals as the only goals; your opinion as the only opinion; your confidence as correctness. Saying you know better is not the same as explaining you know better.

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others studying the Monastery: (13)
As of 2014-07-10 15:24 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    When choosing user names for websites, I prefer to use:








    Results (213 votes), past polls