Grand Temple problem : extra information needed

It seems that some information/constraints are missing from the question. It does not specify the boundary/limits of the coordinates which we need to consider. Like what is the max unit on the x and y axis which we need to consider;

hey @shubh17, consider them as contraints x[100001],y[100001]

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.

If the constraints for x and y are so high, then I think the answer to the given answer should also be quite a big number since if lets say there are towers at the given points, the temple can be made starting from a length/breadth till the limit of x/y.

hey @shubh17, what is your query then.

My query is that the output will not be 2 for the given test case if the king has such huge amount of land (100001 on both x and y axis). Only 3 coordinates with rivers flowing at (1,1), (2,4) and (5,2). By drawing a diagram it seems that a huge area is empty towards the right side (x-axis) and upper side (Y-axis). I think the constraints should be a lower number to arrive at this answer.

hey @shubh17, it will be 2 only. constraints x[100001],y[100001] means maximum 100001 coordinates of river are given.