What does it mean when -1.000000 comes as an error in an interactive problem?
“Then, you should read a line containing a single integer. If this integer is non-negative, it denotes the answer to your query. Otherwise, it means that you exceeded the limit on the number of queries, the coordinates you printed are invalid or some other error occured.”
Hope this helps