結果

問題 No.431 死亡フラグ
ユーザー hermione17hermione17
提出日時 2016-10-14 22:30:49
言語 Java21
(openjdk 21)
結果
AC  
実行時間 126 ms / 2,000 ms
コード長 483 bytes
コンパイル時間 4,487 ms
コンパイル使用メモリ 71,256 KB
実行使用メモリ 56,240 KB
最終ジャッジ日時 2023-08-14 11:05:56
合計ジャッジ時間 7,512 ms
ジャッジサーバーID
(参考情報)
judge12 / judge13
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 123 ms
55,692 KB
testcase_01 AC 124 ms
56,240 KB
testcase_02 AC 124 ms
55,412 KB
testcase_03 AC 123 ms
55,888 KB
testcase_04 AC 123 ms
55,888 KB
testcase_05 AC 124 ms
55,932 KB
testcase_06 AC 124 ms
55,540 KB
testcase_07 AC 123 ms
55,388 KB
testcase_08 AC 123 ms
55,760 KB
testcase_09 AC 125 ms
55,840 KB
testcase_10 AC 126 ms
55,632 KB
testcase_11 AC 126 ms
56,032 KB
testcase_12 AC 126 ms
55,544 KB
testcase_13 AC 126 ms
55,856 KB
testcase_14 AC 126 ms
55,756 KB
testcase_15 AC 125 ms
55,532 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.io.PrintStream;
import java.util.Scanner;


public class Y431 {
	Y431() throws Exception {
		Scanner in = new Scanner(System.in);
		PrintStream out = new PrintStream(System.out);

		int d1 = in.nextInt();
		int d2 = in.nextInt();
		int d3 = in.nextInt();
		int s = in.nextInt();
		
		if (s == 1 || (d1 + d2 + d3) < 2) out.println("SURVIVED");
		else out.println("DEAD");
		
		out.close();
	}

	public static void main(String argv[]) throws Exception {
		new Y431();
	}
}
0