結果
| 問題 | No.136 Yet Another GCD Problem |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2026-07-20 19:18:28 |
| 言語 | PyPy3 (7.3.17) |
| 結果 |
AC
|
| 実行時間 | 73 ms / 5,000 ms |
| + 349µs | |
| コード長 | 299 bytes |
| 記録 | |
| コンパイル時間 | 241 ms |
| コンパイル使用メモリ | 96,304 KB |
| 実行使用メモリ | 79,360 KB |
| 最終ジャッジ日時 | 2026-07-20 19:18:43 |
| 合計ジャッジ時間 | 5,139 ms |
|
ジャッジサーバーID (参考情報) |
judge2_0 / judge3_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 39 |
ソースコード
from math import isqrt
def divsor(x):
arr = []
for i in range(1,isqrt(x)+1):
if x % i == 0:
arr.append(i)
if i*i != x:
arr.append(x//i)
return arr
N,K = map(int,input().split())
ans = 0
for a in divsor(N):
if a != N:
ans = max(ans, a)
print(ans)