s,w = list(map(int, input().split()))

print(("unsafe" if s <= w else "safe"))
s,w=list(map(int,input().split()))

print(("unsafe" if w>=s else "safe"))
s, w = list(map(int, input().split()))
print(("unsafe" if s <= w else "safe"))

s, w = list(map(int, input().split()))
print(("unsafe" if w >= s else "safe"))

-print(("unsafe" if s <= w else "safe")) +print(("unsafe" if w >= s else "safe"))