Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic
 
PerlMonks  

Re: PGA Golf, Round 1

by mr.nick (Chaplain)
on May 24, 2001 at 21:15 UTC ( [id://83007]=note: print w/replies, xml ) Need Help??


in reply to PGA Golf, Round 1

Okay: here are my entries. They aren't particularly good, but they work which is fine for me.

Hole 1 - 21 chars

(split/[^\w_]/,pop)[4] 1234567890123456789001
Hole 2 - 24 chars
perl -e'\ \ \ \ goto TPC'
Hole 4 - 31 chars
map{chr(hex)}unpack("A2"x11,pop) 1234567890123456789012345678901
Hole 5 - 32 chars
$x=shift;map{$x=$_ if$_<$x}@_;$x 12345678901234567890123456789012
Hole 6 - 53 chars (ugh!)
sort{($a=~/([aeoui])/)[0]cmp($b=~/([aeiou])/)[0]}@_} 1234567890123456789012345678901234567890123456890123

Replies are listed 'Best First'.
Re: Re: PGA Golf, Round 1
by suaveant (Parson) on May 24, 2001 at 23:17 UTC
    I feel so smart... I actually pulled an obscure thing of my own... in perl // redoes the previous re, so
    sub hole{sort{($a=~/([aeiou])/)[0]cmp($b=~//)[0]}@_} 123456789_123456789_123456789_123456789_12
    cuts your hole 6 to 42 chars! my small moment of glory...

    Update realized I counted } in sub... actually 42 chars.. not 43...
                    - Ant

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others musing on the Monastery: (6)
As of 2024-03-28 14:05 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found