結果
問題 | No.489 株に挑戦 |
ユーザー |
![]() |
提出日時 | 2017-08-02 14:38:09 |
言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
結果 |
TLE
|
実行時間 | - |
コード長 | 406 bytes |
コンパイル時間 | 410 ms |
コンパイル使用メモリ | 12,544 KB |
実行使用メモリ | 16,384 KB |
最終ジャッジ日時 | 2024-10-11 12:57:15 |
合計ジャッジ時間 | 5,297 ms |
ジャッジサーバーID (参考情報) |
judge3 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | -- * 3 |
other | TLE * 2 -- * 33 |
ソースコード
N,D,K = [int(i) for i in input().split()] A = [] max = 0 d1,d2 = 0,0 for i in range(N): if len(A) > D: del A[0] A.append(int(input())) if max < A[-1]-min(A): max = A[-1]-min(A) d2 = i if len(A) < D: d1 = i-(len(A)-1)+A.index(min(A)) else: d1 = i-D+A.index(min(A)) if max == 0: print(0) else: print(max*K) print(d1,d2)