結果

問題 No.1808 Fullgold Alchemist
ユーザー yudedakoyudedako
提出日時 2022-01-24 22:33:54
言語 Scala(Beta)
(3.4.0)
結果
AC  
実行時間 1,276 ms / 2,000 ms
コード長 357 bytes
コンパイル時間 15,388 ms
コンパイル使用メモリ 256,404 KB
実行使用メモリ 82,892 KB
最終ジャッジ日時 2024-12-15 01:52:53
合計ジャッジ時間 56,931 ms
ジャッジサーバーID
(参考情報)
judge4 / judge3
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 939 ms
63,040 KB
testcase_01 AC 937 ms
63,008 KB
testcase_02 AC 934 ms
63,088 KB
testcase_03 AC 924 ms
63,160 KB
testcase_04 AC 929 ms
63,136 KB
testcase_05 AC 1,118 ms
75,208 KB
testcase_06 AC 1,167 ms
78,432 KB
testcase_07 AC 1,164 ms
78,332 KB
testcase_08 AC 1,166 ms
81,684 KB
testcase_09 AC 1,219 ms
81,560 KB
testcase_10 AC 1,211 ms
81,576 KB
testcase_11 AC 1,245 ms
82,892 KB
testcase_12 AC 1,251 ms
78,648 KB
testcase_13 AC 1,276 ms
78,872 KB
testcase_14 AC 1,172 ms
78,760 KB
testcase_15 AC 1,144 ms
78,540 KB
testcase_16 AC 971 ms
63,268 KB
testcase_17 AC 936 ms
63,116 KB
testcase_18 AC 1,045 ms
63,408 KB
testcase_19 AC 974 ms
63,236 KB
testcase_20 AC 1,013 ms
65,284 KB
testcase_21 AC 1,005 ms
63,396 KB
testcase_22 AC 925 ms
63,156 KB
testcase_23 AC 952 ms
63,140 KB
testcase_24 AC 967 ms
63,056 KB
testcase_25 AC 993 ms
63,204 KB
testcase_26 AC 1,024 ms
63,436 KB
testcase_27 AC 1,018 ms
65,176 KB
testcase_28 AC 1,168 ms
79,040 KB
testcase_29 AC 1,060 ms
66,968 KB
testcase_30 AC 1,007 ms
65,928 KB
testcase_31 AC 1,140 ms
78,628 KB
testcase_32 AC 1,117 ms
70,332 KB
testcase_33 AC 1,146 ms
76,384 KB
testcase_34 AC 1,188 ms
78,884 KB
testcase_35 AC 1,171 ms
74,232 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import scala.io.StdIn.*
import scala.math.min

@main def main =
  val Array(n, m) = readLine().split(' ').map(_.toInt)
  val ore = readLine().split(' ').map(_.toInt)
  var sum = 0L
  var minAverage = Long.MaxValue
  for i <- 0 until n do
    sum += ore(i)
    val average = (sum / (i + 1)) / m
    minAverage = min(average, minAverage)
  println(minAverage)
0