grader is the one who is giving the input right?
the different values of y are given based on program?
you have to print values of y and then grader will tell you 0,1,-1 and then you try printing some new y again until you get answer. Then just print answer in the end.
If your problem is with interactive part of the program go through this: https://discuss.codechef.com/questions/141708/interactive-problems-and-the-way-to-deal-with-them
still my program is compiling wrongly. is there any way i can show you my progam
not until contest is over.