
ZOJ Problem Set  1574
We know there are infinite Pythagorean Triples, such as (3, 4, 5). If (x, y, z) is a Pythagorean Triple and satisfies x < y < z, gcd(x, y, z) = 1, we refer to it as basic Pythagorean Triple. Now we shall sort all basic Pythagorean Triples, first on x, then on y.
One integer each line, 0 < n <= 100,000.
The nth basic Pythagorean Triple on a line.
1
3 4 5
Author: CHEN, Gaoli Source: ZOJ Monthly, April 2003 