for x = 1 to 20 for y = x to 20 for z = y to 20 if pow(x,2) + pow(y,2) = pow(z,2) see "[" + x + "," + y + "," + z + "]" + nl ok next next next