D1,D2,D3,S=(int(i) for i in input ().split()) if S==1: print ("SURVIVED") elif D1+D2+D3>1: print ("DEAD") else: print ("SURVIVED")