結果
問題 | No.33 アメーバがたくさん |
ユーザー | pluto77 |
提出日時 | 2018-02-15 14:53:03 |
言語 | Python2 (2.7.18) |
結果 |
WA
|
実行時間 | - |
コード長 | 319 bytes |
コンパイル時間 | 969 ms |
コンパイル使用メモリ | 6,672 KB |
実行使用メモリ | 6,140 KB |
最終ジャッジ日時 | 2023-08-26 21:41:01 |
合計ジャッジ時間 | 1,745 ms |
ジャッジサーバーID (参考情報) |
judge13 / judge11 |
(要ログイン)
テストケース
テストケース表示入力 | 結果 | 実行時間 実行使用メモリ |
---|---|---|
testcase_00 | WA | - |
testcase_01 | WA | - |
testcase_02 | WA | - |
testcase_03 | WA | - |
testcase_04 | WA | - |
testcase_05 | WA | - |
testcase_06 | WA | - |
testcase_07 | WA | - |
testcase_08 | WA | - |
testcase_09 | WA | - |
testcase_10 | WA | - |
ソースコード
n,d,t=map(int, raw_input().split()) dic={} for i in map(int,raw_input().split()): j=(i%d+d)%d if j in dic: dic[j].append(i) else: dic[j]=[i] print dic res = 0 for k, v in dic.items(): res+=len(v)+t*2 for i in xrange(len(v)-1): if v[i]+t*d<v[i+1]-t*d: res+=t*2 else: res+=(v[i+1]-v[i])/d-1 print res