結果

問題 No.431 死亡フラグ
ユーザー satumaimosatumaimo
提出日時 2017-07-07 18:09:56
言語 Java21
(openjdk 21)
結果
AC  
実行時間 146 ms / 2,000 ms
コード長 663 bytes
コンパイル時間 2,238 ms
コンパイル使用メモリ 74,628 KB
実行使用メモリ 41,740 KB
最終ジャッジ日時 2024-04-16 01:16:09
合計ジャッジ時間 5,313 ms
ジャッジサーバーID
(参考情報)
judge3 / judge1
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 137 ms
41,476 KB
testcase_01 AC 146 ms
41,496 KB
testcase_02 AC 140 ms
41,308 KB
testcase_03 AC 140 ms
41,612 KB
testcase_04 AC 138 ms
41,340 KB
testcase_05 AC 138 ms
41,740 KB
testcase_06 AC 143 ms
41,636 KB
testcase_07 AC 142 ms
41,304 KB
testcase_08 AC 142 ms
41,500 KB
testcase_09 AC 139 ms
41,196 KB
testcase_10 AC 141 ms
41,516 KB
testcase_11 AC 139 ms
41,240 KB
testcase_12 AC 145 ms
41,252 KB
testcase_13 AC 138 ms
41,236 KB
testcase_14 AC 141 ms
41,384 KB
testcase_15 AC 143 ms
41,636 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.util.Scanner;
public class Main {
    public static void main(String[] args) throws Exception {
        Scanner s = new Scanner(System.in);
        int a = s.nextInt();
        int b = s.nextInt();
        int c = s.nextInt();
        int d = s.nextInt();
        if (d == 1){
            System.out.println("SURVIVED");
        }else if (a+b+c<2){
            System.out.println("SURVIVED");
        } else{
            System.out.println("DEAD");
        }
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        String line = br.readLine();
    }
}
0