結果

問題 No.431 死亡フラグ
ユーザー shinwisteria
提出日時 2017-03-30 17:41:53
言語 Java
(openjdk 23)
結果
AC  
実行時間 116 ms / 2,000 ms
コード長 355 bytes
コンパイル時間 3,505 ms
コンパイル使用メモリ 74,672 KB
実行使用メモリ 41,552 KB
最終ジャッジ日時 2024-07-07 03:02:28
合計ジャッジ時間 5,310 ms
ジャッジサーバーID
(参考情報)
judge2 / judge3
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other AC * 16
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.Scanner;
public class Flag {

	public static void main(String[] args) {
		Scanner s = new Scanner(System.in);
		int count = 0;
		for(int i = 0;i < 3;i++){
			if(s.nextInt() == 1){
				count++;
			}
		}
		if(s.nextInt() == 1 || count < 2){
			System.out.println("SURVIVED");
		}else{
			System.out.println("DEAD");
		}
		s.close();

	}

}
0