結果

問題 No.2194 兄弟の掛け引き
ユーザー _lS_RRoRbT_lS_RRoRbT
提出日時 2023-01-20 22:25:24
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 81 ms / 1,000 ms
コード長 276 bytes
コンパイル時間 339 ms
コンパイル使用メモリ 87,004 KB
実行使用メモリ 71,600 KB
最終ジャッジ日時 2023-09-05 14:44:25
合計ジャッジ時間 2,526 ms
ジャッジサーバーID
(参考情報)
judge12 / judge11
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 76 ms
71,440 KB
testcase_01 AC 75 ms
71,556 KB
testcase_02 AC 74 ms
71,568 KB
testcase_03 AC 76 ms
71,304 KB
testcase_04 AC 75 ms
71,396 KB
testcase_05 AC 76 ms
71,412 KB
testcase_06 AC 74 ms
71,600 KB
testcase_07 AC 75 ms
71,520 KB
testcase_08 AC 77 ms
71,112 KB
testcase_09 AC 78 ms
71,208 KB
testcase_10 AC 79 ms
71,132 KB
testcase_11 AC 81 ms
71,556 KB
testcase_12 AC 80 ms
71,208 KB
testcase_13 AC 78 ms
71,364 KB
testcase_14 AC 77 ms
71,380 KB
testcase_15 AC 76 ms
71,248 KB
testcase_16 AC 78 ms
71,480 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

a, b, c = map(int, input().split())
ans = []
if c % a == 0:
    n = c // a
    if n * a <= b:
        ans.append(n)
if (c + b) % a == 0:
    m = (c + b) // a
    if m * a > b:
        ans.append(m)

ans.sort()
if not ans:
    print(-1)
else:
    for e in ans:
        print(e)
0