import java.util.*; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int o= 0 ,p = 0,q = 0; int a = Integer.parseInt(sc.next()); int b = Integer.parseInt(sc.next()); int c = Integer.parseInt(sc.next()); int d = Integer.parseInt(sc.next()); // int[] test = new int[100000]; // char[] c1 = s1.toCharArray(); /* while(true){ test[o] = Integer.parseInt(sc.next()); o++; if(o==s)break; } */ if(a==1)o++; if(b==1)o++; if(c==1)o++; if(d==1)o-=5; if(o>1)System.out.print("DEAD"); else System.out.print("SURVIVED"); System.out.println(); } }