Pythagoras’ theorem

As Beremiz reminded a sheikh, this is the famous Pythagoras’ theorem:

“In any right triangle, the square of the hypotenuse equals the sum of
the squares of the legs.”

Input

Input consists of several cases, each with three natural numbers between
1 and 10⁴.

Output

Print a line for every case. If the three given numbers can be the sides
of a right triangle, print its area (it will always be integer).
Otherwise, if they can be the sides of a non-degenerate triangle (i.e.,
with strictly positive area), print “yes”. Otherwise, print “no”.

Problem information

Author: Unknown
Translator: Salvador Roura

Generation: 2026-01-25T11:07:22.246Z

© Jutge.org, 2006–2026.
https://jutge.org
