結果

問題 No.176 2種類の切手
ユーザー roarisroaris
提出日時 2019-12-09 14:43:17
言語 PyPy3
(7.3.13)
結果
WA  
実行時間 -
コード長 182 bytes
コンパイル時間 872 ms
コンパイル使用メモリ 87,208 KB
実行使用メモリ 75,576 KB
最終ジャッジ日時 2023-09-04 05:59:12
合計ジャッジ時間 5,214 ms
ジャッジサーバーID
(参考情報)
judge15 / judge13
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 74 ms
71,228 KB
testcase_01 AC 78 ms
71,272 KB
testcase_02 AC 75 ms
71,240 KB
testcase_03 AC 78 ms
71,216 KB
testcase_04 AC 80 ms
71,316 KB
testcase_05 AC 77 ms
71,484 KB
testcase_06 AC 76 ms
71,192 KB
testcase_07 AC 77 ms
71,484 KB
testcase_08 AC 74 ms
71,300 KB
testcase_09 AC 77 ms
71,176 KB
testcase_10 WA -
testcase_11 WA -
testcase_12 AC 76 ms
71,380 KB
testcase_13 AC 77 ms
71,256 KB
testcase_14 AC 76 ms
71,292 KB
testcase_15 AC 74 ms
71,144 KB
testcase_16 AC 75 ms
71,300 KB
testcase_17 WA -
testcase_18 AC 75 ms
71,224 KB
testcase_19 AC 75 ms
71,544 KB
testcase_20 AC 76 ms
71,244 KB
testcase_21 AC 76 ms
71,352 KB
testcase_22 AC 75 ms
71,220 KB
testcase_23 AC 77 ms
71,416 KB
testcase_24 AC 78 ms
71,448 KB
testcase_25 WA -
testcase_26 AC 77 ms
71,392 KB
testcase_27 AC 78 ms
71,268 KB
testcase_28 AC 77 ms
71,184 KB
testcase_29 AC 84 ms
75,472 KB
testcase_30 AC 80 ms
75,576 KB
testcase_31 AC 76 ms
71,332 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

A, B, T = map(int, input().split())
i = 0
ans = 10**18

while True:
    if i>=A or B*i>T:
        break
    
    j = (T-i*B+A-1)//A
    ans = min(ans, A*j+B*i)
    i += 1

print(ans)
0