Sort 100 Discussions, By:
Please Login in order to post a comment
AN USELESS SPOILER:
This problem has an O(0) solution, believe it or not.
Not a good idea to show the method directly. Calm down and analyze the problem.
Edit after a year: calm down and do some mathematical stuff. You can make it!
Grab some pen and paper. This is purely a mathematical problem.
What a troll question
Adding to the chorus of not-quite-spoilery comments, this challenge has nothing to do with your coding abilities and everything to do with your ability to look up the properties of a primitive Pythagorean triple.
Worst problem ever... who comes up with this stuff? Errors even in the problem definition.
I wish I had came to the discussion section earlier. I wasted so much time on this.