結果
問題 | No.2260 Adic Sum |
ユーザー |
![]() |
提出日時 | 2023-03-26 12:54:30 |
言語 | PyPy3 (7.3.15) |
結果 |
AC
|
実行時間 | 516 ms / 2,000 ms |
コード長 | 302 bytes |
コンパイル時間 | 350 ms |
コンパイル使用メモリ | 82,304 KB |
実行使用メモリ | 200,296 KB |
最終ジャッジ日時 | 2024-10-06 06:51:39 |
合計ジャッジ時間 | 6,390 ms |
ジャッジサーバーID (参考情報) |
judge2 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 33 |
ソースコード
from collections import defaultdictimport sysinput = sys.stdin.readlineN, P = map(int, input().split())A = list(map(int, input().split()))p = Pans = 0while p <= 10**10:cnt = defaultdict(int)for x in A:r = x % pans += cnt[r]cnt[r] += 1p *= Pprint(ans)