Hi, I’m facing issue in this question regarding Pythagorean triplets. Please review my code : https://ide.codingblocks.com/s/177623
I’m getting 3 failed cases. Took help from the hint video as well. Still not sure what I’m doing wrong here.
Hi, I’m facing issue in this question regarding Pythagorean triplets. Please review my code : https://ide.codingblocks.com/s/177623
I’m getting 3 failed cases. Took help from the hint video as well. Still not sure what I’m doing wrong here.
@simar94.singh
Firstly, the test case can be 10^9 so change your data types to long long int.
Secondly,
Consider a test case:
1
Your Output:
0 1
Expected Output:
-1
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.