結果
問題 |
No.2627 Unnatural Pitch
|
ユーザー |
|
提出日時 | 2024-02-09 23:04:12 |
言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
結果 |
WA
|
実行時間 | - |
コード長 | 262 bytes |
コンパイル時間 | 78 ms |
コンパイル使用メモリ | 12,672 KB |
実行使用メモリ | 33,780 KB |
最終ジャッジ日時 | 2024-09-28 16:14:56 |
合計ジャッジ時間 | 4,580 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge4 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 1 WA * 2 |
other | AC * 6 WA * 17 |
ソースコード
n,k,l,u=map(int,input().split()) mid=(l+u)//2 A=[int(_) for _ in input().split()] avg=sum(A)//n un_nature=0 for i in range(n): tmp=A[i]+mid-avg if tmp<l: un_nature+=(l-tmp+k-1)//k elif tmp>u: un_nature+=(tmp-u+k-1)//k print(un_nature)