結果
| 問題 |
No.2755 行列の共役類
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2024-05-10 22:20:00 |
| 言語 | PyPy3 (7.3.15) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 462 bytes |
| コンパイル時間 | 378 ms |
| コンパイル使用メモリ | 82,156 KB |
| 実行使用メモリ | 67,084 KB |
| 最終ジャッジ日時 | 2024-12-20 06:03:39 |
| 合計ジャッジ時間 | 6,018 ms |
|
ジャッジサーバーID (参考情報) |
judge3 / judge1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 9 WA * 7 RE * 50 |
ソースコード
def is_prime(N: int):
if N <= 1:
return False
if N == 2:
return True
if N % 2 == 0:
return False
s = 0
d = N - 1
while d % 2 == 0:
s += 1
d >>= 1
for a in [2, 325, 9375, 28178, 450775, 9780504, 1795265022]:
if a % N == 0:
return True
x = pow(a, d, N)
if x != 1:
t = 0
while t < s and x < N - 1:
t += 1
x = x * x % N
if t == s:
return False
return True
B, C = map(int, input().split())
assert(C == 1)
print("100+")