in reply to Re (tilly) 1: (Golf) Nearest Neighbors
in thread (Golf) Nearest Neighbors
OK, a couple of simple typographic manipulations to bring it to 55:
p
(There are advantages to being slow (or having no time!)).  I was still up over 80 strokes with my sort-based solution when I looked up and saw this guy casually strolling past Tiger Woods.sub nn { ()=sort{abs$a-$b>abs$_[0]-$_[1]or@_=($a,$b);$a-$b}@_;@_ }
p
|
---|
In Section
Obfuscated Code