DS = list(map(int, input().split())) if DS[-1]==1: print("SURVIVED") else: if sum(DS[:3])>=2: print("DEAD") else: print("SURVIVED")