*A,=map(int,input().split()) print('SURVIVED' if A[-1] == 1 or sum(A[:3] < 2) else 'DEAD')