結果

問題 No.21 平均の差
コンテスト
ユーザー 💕💖💞
提出日時 2017-04-08 18:33:21
言語 Kotlin
(2.4.10 + ACL)
コンパイル:
kotlinc -cp /opt/aclib/ac_library.jar _filename_ -include-runtime -d main.jar
実行:
java -cp main.jar:/opt/aclib/ac_library.jar _class_
結果
AC  
実行時間 192 ms / 5,000 ms
コード長 182 bytes
記録
記録タグの例:
初AC ショートコード 純ショートコード 純主流ショートコード 最速実行時間
コンパイル時間 8,405 ms
コンパイル使用メモリ 465,508 KB
実行使用メモリ 52,236 KB
最終ジャッジ日時 2026-05-14 09:08:24
合計ジャッジ時間 11,263 ms
ジャッジサーバーID
(参考情報)
judge2_1 / judge3_0
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other AC * 10
権限があれば一括ダウンロードができます
コンパイルメッセージ
Main.kt:7:21: warning: unnecessary non-null assertion (!!) on a non-null receiver of type 'Int'.
  println(eval.max()!! - eval.min()!!)
                    ^^
Main.kt:7:36: warning: unnecessary non-null assertion (!!) on a non-null receiver of type 'Int'.
  println(eval.max()!! - eval.min()!!)
                                   ^^

ソースコード

diff #
raw source code

fun main(args: Array<String>) {
  val n = readLine()!!.toInt()
  readLine()
  val eval = (1..n).map { 
    readLine()!!.toInt()
  }.toList()
  println(eval.max()!! - eval.min()!!)
}
0