Beefy Boxes and Bandwidth Generously Provided by pair Networks
Don't ask to ask, just ask

Re: PGA Golf, Round 1

by srawls (Friar)
on May 25, 2001 at 00:38 UTC ( #83125=note: print w/replies, xml ) Need Help??

in reply to PGA Golf, Round 1

Hole #5 -- 27 chars (now 34, added $t-pop;):
sub MAX {$t=pop; (grep{$t<$_?$t=$_:0}@_)[-1] }

Update:Changed code--it didn't handle negative numbers before. (thanks for the /msg chemboy)

The 15 year old, freshman programmer,
Stephen Rawls

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://83125]
[Discipulus]: my last linux experience was with redhad 5.6 and occasionally with partedmagic.. i need to relearn everything.. :=(
[choroba]: command line FTW!
[marto]: good morning all, sane dots all round

How do I use this? | Other CB clients
Other Users?
Others having an uproarious good time at the Monastery: (7)
As of 2016-12-07 09:13 GMT
Find Nodes?
    Voting Booth?
    On a regular basis, I'm most likely to spy upon:

    Results (125 votes). Check out past polls.