#include int main(void){ int i; int D[4], S, n = 0; scanf("%d %d %d %d", &D[1], &D[2], &D[3], &S); for(i = 1; i <= 3; i++){ if(D[i] == 1) n++; } if(S == 1) printf("SURVIVED\n"); else if(n < 2) printf("SURVIVED\n"); else printf("DEAD\n"); return 0; }