x, y = [int(x) for x in input().split()]
if (x**2 + y**2 > 1) and (x**2 + y**2 < 2):
print('In the ring')
else:
print('Out of')
x, y = [int(x) for x in input().split()]
if (x**2 + y**2 > 1) and (x**2 + y**2 < 2):
print('In the ring')
else:
print('Out of')