結果

問題 No.394 ハーフパイプ(1)
ユーザー komkomhkomkomh
提出日時 2019-06-10 08:21:43
言語 Kotlin
(1.9.10)
結果
AC  
実行時間 336 ms / 2,000 ms
コード長 180 bytes
コンパイル時間 13,952 ms
コンパイル使用メモリ 422,488 KB
実行使用メモリ 55,788 KB
最終ジャッジ日時 2023-08-13 02:33:42
合計ジャッジ時間 17,552 ms
ジャッジサーバーID
(参考情報)
judge15 / judge13
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 334 ms
54,200 KB
testcase_01 AC 333 ms
55,788 KB
testcase_02 AC 334 ms
53,964 KB
testcase_03 AC 331 ms
54,104 KB
testcase_04 AC 336 ms
54,212 KB
testcase_05 AC 335 ms
54,256 KB
testcase_06 AC 334 ms
53,976 KB
testcase_07 AC 334 ms
54,040 KB
testcase_08 AC 336 ms
54,204 KB
testcase_09 AC 336 ms
54,356 KB
testcase_10 AC 335 ms
54,108 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
Main.kt:6:23: warning: unnecessary non-null assertion (!!) on a non-null receiver of type Float
    val ans = (S.sum()!! - S.min()!! - S.max()!!) / 4.0
                      ^
Main.kt:6:35: warning: unnecessary non-null assertion (!!) on a non-null receiver of type Float
    val ans = (S.sum()!! - S.min()!! - S.max()!!) / 4.0
                                  ^
Main.kt:6:47: warning: unnecessary non-null assertion (!!) on a non-null receiver of type Float
    val ans = (S.sum()!! - S.min()!! - S.max()!!) / 4.0
                                              ^

ソースコード

diff #

package yukicoder

fun main() {
    val S = readLine()!!.split(" ").map(String::toFloat)

    val ans = (S.sum()!! - S.min()!! - S.max()!!) / 4.0
    println("%.2f".format(ans))
}
0