Problem 9: Special Pythagorean triplet

flag = 0
for a in range(1,1000):
for b in range(a+1,1000):
if a*a + b*b == (1000-a-b)**2:
print(a,b)
flag = 1
break
if flag == 1:
break print(a*b*(1000-a-b))
上一篇:CF1456D. Cakes for Clones


下一篇:完整的拆分nginx访问日志