Can anyone please tell me why I am getting an NZEC error in this program?? I cant find it! http://www.codechef.com/viewsolution/2686919 …please!!
You probably changed indexes somewhere…
In 3rd test case it prints only 3 and failed the last test case.
this is your corrected code…LINK!!!
the error was in ur nested loop the inner loop should range upto “c” while u had written “r”…!!!
Thanks a lot!! Such a silly mistake!!!