結果
| 問題 | No.1808 Fullgold Alchemist |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2022-01-18 14:50:02 |
| 言語 | PyPy3 (7.3.17) |
| 結果 |
AC
|
| 実行時間 | 78 ms / 2,000 ms |
| コード長 | 322 bytes |
| 記録 | |
| コンパイル時間 | 193 ms |
| コンパイル使用メモリ | 85,248 KB |
| 実行使用メモリ | 124,544 KB |
| 最終ジャッジ日時 | 2026-05-17 06:28:50 |
| 合計ジャッジ時間 | 3,309 ms |
|
ジャッジサーバーID (参考情報) |
judge3_0 / judge1_1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 33 |
ソースコード
n,m=map(int,input().split())
a=list(map(int,input().split()))
from itertools import accumulate
s=list(accumulate(a))
def check(x):
for i in range(n):
if s[i]<(i+1)*m*x:
return False
return True
l=0
r=10**15
while r-l>1:
x=(r+l)//2
if check(x):
l=x
else:
r=x
print(l)