結果

問題 No.604 誕生日のお小遣い
ユーザー yansi819yansi819
提出日時 2024-05-16 09:38:16
言語 PyPy3
(7.3.15)
結果
WA  
実行時間 -
コード長 233 bytes
コンパイル時間 157 ms
コンパイル使用メモリ 82,524 KB
実行使用メモリ 53,960 KB
最終ジャッジ日時 2024-05-16 09:38:18
合計ジャッジ時間 2,172 ms
ジャッジサーバーID
(参考情報)
judge3 / judge2
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 34 ms
52,548 KB
testcase_01 AC 33 ms
52,520 KB
testcase_02 AC 32 ms
52,692 KB
testcase_03 AC 36 ms
53,960 KB
testcase_04 WA -
testcase_05 WA -
testcase_06 WA -
testcase_07 AC 33 ms
52,212 KB
testcase_08 WA -
testcase_09 AC 33 ms
53,564 KB
testcase_10 AC 32 ms
52,164 KB
testcase_11 AC 33 ms
52,824 KB
testcase_12 AC 32 ms
52,808 KB
testcase_13 AC 31 ms
52,768 KB
testcase_14 AC 31 ms
52,616 KB
testcase_15 AC 33 ms
52,208 KB
testcase_16 AC 33 ms
52,432 KB
testcase_17 AC 31 ms
53,304 KB
testcase_18 AC 33 ms
52,864 KB
testcase_19 AC 32 ms
52,920 KB
testcase_20 AC 35 ms
52,884 KB
testcase_21 AC 32 ms
52,676 KB
testcase_22 AC 31 ms
53,016 KB
testcase_23 AC 32 ms
53,036 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

A, B, C = map(int, input().split())
left = 1
right = 1000000000000000000
while right - left > 1:
    mid = (left + right) // 2
    if mid - mid // A + (mid // A) * B >= C:
        right = mid
    else:
        left = mid
print(right)
0