結果

問題 No.2194 兄弟の掛け引き
コンテスト
ユーザー n_na
提出日時 2023-01-21 02:56:23
言語 PyPy3
(7.3.17)
コンパイル:
pypy3 -mpy_compile _filename_
実行:
pypy3 _filename_
結果
WA  
実行時間 -
コード長 269 bytes
記録
記録タグの例:
初AC ショートコード 純ショートコード 純主流ショートコード 最速実行時間
コンパイル時間 227 ms
コンパイル使用メモリ 85,392 KB
実行使用メモリ 59,760 KB
最終ジャッジ日時 2026-03-08 10:00:31
合計ジャッジ時間 1,275 ms
ジャッジサーバーID
(参考情報)
judge1 / judge3
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 9 WA * 5
権限があれば一括ダウンロードができます

ソースコード

diff #
raw source code

A,B,C = map(int,input().split())

res = []
k = (B+A-1)//A
for n in range(k,pow(10,5)+1):
    if n*A-B > 0 and C == n*A-B: res.append(n)
    if n*A-B <= 0 and C == n*A: res.append(n)
res.sort()
if not res:
    print(-1)
else:
    for r in res:
        print(r)
        
0