I demand the ugliest (really?) and biggest... but probably fastest solution
It's 131613 instructions long and takes 24 cycles to complete regardless of the number difference.
My program assumes, that values are in the range of 0<=x<=255, which makes it even uglier.
I use a static lookup table of call instructions; either 4c (for mem 0) or 8c (for mem 1)
Then I calculate mem0*256*2+mem1*2 and simply jump to this offset into the lookup table.
The call instruction points back to the start and prints the bigger number.
I did not use spaces for repeating patterns, because this would terribly slow things down.
Code: Select all
24*g0<p!1<p!0<888***1<2*+g4c(254 times 8c)(2 times 4c)(253 times 8c) ... (255 times 8c)
My biggest problem was to submit this gozilla of a program because it always stopped with a network timeout.
Changing the web page to use POST for submit finally worked.
My other solutions were:
Code: Select all
0<1<1^1^/1?dp
0<1<1^1^/3*gp!!dp!dp!dp!dp!dp!dp!dp!dp!dp!dp!dp!
0<1<1^1^-884**+3*gp!!..(several p!!)..p!!dp!..(several dp!)..dp!
The last 2 use the same idea of a lookup table as described above, but the size of the table is smaller because of the achievable size reduction using / and -.
I second your opinion regarding the "Broken* Key*" challenges: @Adum: Enough with this, this is no fun anymore