judge = input() if int(judge[6]) == 0: total = int(judge[0]) + int(judge[2]) + int(judge[4]) if total >= 2: print('DEAD') else: print('SURVIVE') else: print('SURVIVE')