Pythagoras Triplet

What is wrong in this code

Hi @hrithik.anand02,
in ur code make a few changes.

  1. convert int to long long int ans the number can exceed(output) 10^8.
    2)ur code is giving output 0 and 1 for input=1, whereass output should be -1, so try to rectify dis error.
    Hope dis resolve ur doubt

Thanks a lot for help