結果

問題 No.431 死亡フラグ
ユーザー バカらっくバカらっく
提出日時 2022-02-04 10:15:02
言語 Kotlin
(1.9.23)
結果
AC  
実行時間 296 ms / 2,000 ms
コード長 213 bytes
コンパイル時間 12,129 ms
コンパイル使用メモリ 419,528 KB
実行使用メモリ 55,044 KB
最終ジャッジ日時 2023-09-02 03:26:13
合計ジャッジ時間 18,202 ms
ジャッジサーバーID
(参考情報)
judge16 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 296 ms
55,044 KB
testcase_01 AC 295 ms
53,080 KB
testcase_02 AC 286 ms
53,148 KB
testcase_03 AC 289 ms
53,024 KB
testcase_04 AC 294 ms
53,056 KB
testcase_05 AC 292 ms
53,048 KB
testcase_06 AC 288 ms
52,936 KB
testcase_07 AC 292 ms
52,988 KB
testcase_08 AC 286 ms
53,048 KB
testcase_09 AC 290 ms
53,032 KB
testcase_10 AC 291 ms
52,832 KB
testcase_11 AC 290 ms
53,012 KB
testcase_12 AC 287 ms
53,052 KB
testcase_13 AC 292 ms
53,636 KB
testcase_14 AC 293 ms
53,100 KB
testcase_15 AC 290 ms
53,280 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
Main.kt:1:10: warning: parameter 'args' is never used
fun main(args: Array<String>) {
         ^

ソースコード

diff #

fun main(args: Array<String>) {
    val flags = readLine()!!.split(" ").map { it.toInt() == 1 }
    val isSave = flags.last() || flags.dropLast(1).count { it  } < 2
    println(if(isSave) "SURVIVED" else "DEAD")
}
0