과거 이집트인들은 각 변들의 길이가 3, 4, 5인 삼각형이 직각 삼각형인것을 알아냈다. 주어진 세변의 길이로 삼각형이 직각인지 아닌지 구분하시오.
while True:
x = list(map(int, input().split()))
if x[0] == 0 and x[1]==0 and x[2]==0:
break
index=x.index(max(x))
c = x[index]**2
x.pop(index)
ab = sum([_ **2 for _ in x])
if c==ab:
print("right")
else:
print("wrong")