PHCUL: Need help

The code is showing WA even though I implemented as stated in the question. What am I doing wrong? The implementation I did is for 50 points.

It looks like a precision issue. Try using the already available sqrt(x) function in C++ for computing the square root, rather than a custom one.

1 Like

The precision is correct, bug is somewhere else.