Further fix 1996/dalbec

I made the recommended change by the author so that each number is on a
line by itself rather than one long line. I changed the try section to
stop at the output that was the output noted by the judges. This was
possible with the change of making it a newline rather than a space
after each number.

I had originally proposed the change in commit
9b6b5a0376 but I did not implement it
because the output of the command versus what the try section included
was misleading (maybe that was correct :-) ) and when looking at Yusuke
Endoh's output I missed that it continued after the number (he had '...'
but I missed it in the long line of output). I linked to his analysis as
well. Thank you Yusuke for confirming it is correct output!
This commit is contained in:
Cody Boone Ferguson committed 2023-03-20 05:47:21 -07:00
1 parent f86ab4571f
commit 674a05e15e
2 files changed
+16 -4

No files matched your search

+1 -1
View File
@@ -9,7 +9,7 @@ int cain(int I, char **O, int O0, int OO, int l)
!(OO-l+!I||I)?l-1:cain(I-!I-!!I,O,OO,OO,l))
:(O0+OO)%l
:cain(I-I/I-I/I,O,O0,OO+OO/OO,
cain(0,O,O0,OO,I-I-I)+I+1?1:printf("%d ",I-I-I)+fflush(stdout))
cain(0,O,O0,OO,I-I-I)+I+1?1:printf("%d\n",I-I-I)+fflush(stdout))
:cain(I-I-I-I-I,O,I+I-I+I,I,0)
:cain(~!!I-!!I,O,atoi(1[O]),1,atoi(0[O]));
}