a,b,c,d=[int(i)+1 for i in input().split()] if a*b*c>=4 and d==1: print('DEAD') else: print('SURVIVED')