Hi everybody .
I participated in the CodeChef's June Cook Off challenge ... or should i say i tried to participate in it . The reason being ,i got stuck at the very first problem . Every time i submit the solution i got TLE. The frustration continued for about 2 hrs with no luck what so ever. I asked the problem setters/testers there to please explain what was the problem but got no response (even after the contest was over). So i was hoping u guys could help me . Its not much of a problem (that was the frustrating part).
The problem is available at :
http://www.codechef.com/problems/KNIGHTMV/
I have my solutions as : ( in the order .... lastest solution to the oldest solution )
http://www.codechef.com/viewsolution/578839
http://www.codechef.com/viewsolution/578334
http://www.codechef.com/viewsolution/578234
http://www.codechef.com/viewsolution/578111
I am no expert in programming (as reflected in the color of my handle) ... so i guess the error(if any) will be minor.
If you got time ....please go through it .. will appreciate any help .... Thanks. :)
http://pastie.org/2092670
Writing 50000 lines without buffering is not a good idea, especially on CodeChef and Anton Lunyov's contests which are known for impossible java time limits.