in reply to Re: Re: Re: Re: (Golf) Kaprekar's Process
in thread (Golf) Kaprekar's Process
sub k { $_=$-x3|pop;!/495/&&1+k(-($_=join$k,sort/./g)+reverse) }
Update:Nice catch Sean. I tested it, just not against numbers like 100 233. It looks like the am wins then, unless that can be beaten.
The 15 year old, freshman programmer,
Stephen Rawls
|
---|