I tried solving TOWCNT but could not find the test case where my solution might fail. Can anyone please provide the test case? Here is my submission (https://www.codechef.com/viewsolution/32091852)
1 6 2 0 1 2 1 1 4
The output must be
@physics0523 Thank you very much. I thought all x’s were distinct
same here and I got lots of penalties.
Will get -150 ratings.
Me too Got 5 penalties
Can somebody help me out as well, i have been debugging for over an hour, couldn’t find a test case which would fail on my solution.
My submission :- https://www.codechef.com/viewsolution/32092045
Though i don’t think the submission would help much (its kinda messy), if any one has any test cases they came up with, you can post it here, that would help too.
P.S. mine works on @physics0523 ’ s test case.
Same with me, cannot find the failing case :- https://www.codechef.com/viewsolution/32093175
Can someone help?
@l_returns Thanks a lot! This was the case, found the mistake
@l_returns Thanks mate, that resolved my issue.
1 6 3
0 1 1
0 4 2
1 5 2
answer should be 1 1 2 2
If you still don't get this, click here
You forgot to sort the answers according to the original order before printing. XD
Also, infinity is “1/0” not “9999999999... / 1”
Replace it with “1/0” instead. Otherwise value can overflow. Idk if it is also creating issues.
Thanks, it’s done now! Actually I corrected that sorting thing before reading you reply but I never thought of that 99999… n infinity thing, that was creating hell! I thought it won’t make difference, but it was making, thanks