# No.431 死亡フラグ flags = [int(i) for i in input().split()] if flags[3] == 1 or flags[:3].count(1) < 2: print('SURVIVED') else: print('DEAD')