結果

問題 No.3253 Banned Product
ユーザー miztom
提出日時 2025-09-06 02:19:25
言語 PyPy3
(7.3.15)
結果
TLE  
実行時間 -
コード長 243 bytes
コンパイル時間 323 ms
コンパイル使用メモリ 82,412 KB
実行使用メモリ 66,052 KB
最終ジャッジ日時 2025-09-06 02:19:29
合計ジャッジ時間 4,313 ms
ジャッジサーバーID
(参考情報)
judge1 / judge4
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 1
other AC * 2 TLE * 1 -- * 6
権限があれば一括ダウンロードができます

ソースコード

diff #

def f(x,k):
    for i in range(1,k+1):
        if x%i<1 and x//i<=k:return 0
    return 1
for i in range(int(input())):
    n,k=map(int,input().split());p=500
    while n*p:
        if f(n,k):print(n);break
        n-=1;p-=1
    else:print(-1)
0