a=input().split() b=0 for i in a: if i=="1": b+=1 if b>=2 and i=="0": print("DEAD") else: print("SURVIVED")