d = list(map(int,input().split())) d2 = d[0]+d[1]+d[2] if d[-1] == 1 or d2 < 2: print("SURVIVED") else: print("DEAD")