結果

問題 No.3056 量子コンピュータで素因数分解 Easy
ユーザー 👑 MizarMizar
提出日時 2022-10-02 01:41:55
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
WA  
(最新)
AC  
(最初)
実行時間 -
コード長 133 bytes
コンパイル時間 100 ms
コンパイル使用メモリ 10,500 KB
実行使用メモリ 24,420 KB
平均クエリ数 2.00
最終ジャッジ日時 2023-08-30 07:02:00
合計ジャッジ時間 6,589 ms
ジャッジサーバーID
(参考情報)
judge13 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 64 ms
23,788 KB
testcase_01 WA -
testcase_02 AC 519 ms
23,560 KB
testcase_03 AC 511 ms
23,856 KB
testcase_04 AC 85 ms
23,780 KB
testcase_05 AC 95 ms
24,176 KB
testcase_06 AC 104 ms
24,048 KB
testcase_07 AC 107 ms
23,868 KB
testcase_08 AC 110 ms
24,060 KB
testcase_09 AC 118 ms
23,832 KB
testcase_10 AC 128 ms
24,024 KB
testcase_11 AC 140 ms
24,024 KB
testcase_12 AC 146 ms
23,688 KB
testcase_13 AC 144 ms
24,324 KB
testcase_14 AC 159 ms
23,704 KB
testcase_15 AC 187 ms
23,656 KB
testcase_16 AC 212 ms
24,324 KB
testcase_17 AC 230 ms
23,728 KB
testcase_18 AC 240 ms
23,512 KB
testcase_19 AC 271 ms
24,420 KB
testcase_20 AC 304 ms
23,668 KB
testcase_21 AC 168 ms
23,724 KB
testcase_22 AC 193 ms
23,836 KB
testcase_23 AC 241 ms
23,812 KB
testcase_24 AC 262 ms
23,712 KB
testcase_25 AC 56 ms
24,276 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import math;n=int(input());print("?",2);r=int(input());print("!",g:=max([math.gcd(n,pow(b,r>>1-r%2,n)-1)%n for b in range(99)]),n//g)
0