import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; public class No00000431_Main { static BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); public static void main(String[] args) throws IOException { String[] x = br.readLine().split(" "); if("1".equals(x[3])) { System.out.println("SURVIVED"); } else { int cnt = 0; for(int i = 0; i < 3; i++) { if("1".equals(x[i])) cnt++; } if(cnt < 2) { System.out.println("SURVIVED"); } else { System.out.println("DEAD"); } } } }