結果

問題 No.2099 [Cherry Alpha B] Time Machine
ユーザー kyskys
提出日時 2022-10-14 21:31:50
言語 PyPy3
(7.3.15)
結果
WA  
実行時間 -
コード長 818 bytes
コンパイル時間 1,111 ms
コンパイル使用メモリ 86,820 KB
実行使用メモリ 76,144 KB
最終ジャッジ日時 2023-09-08 20:22:29
合計ジャッジ時間 30,469 ms
ジャッジサーバーID
(参考情報)
judge15 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 363 ms
75,404 KB
testcase_01 AC 367 ms
75,340 KB
testcase_02 AC 364 ms
75,248 KB
testcase_03 AC 367 ms
75,340 KB
testcase_04 WA -
testcase_05 AC 366 ms
75,508 KB
testcase_06 AC 367 ms
75,500 KB
testcase_07 AC 363 ms
75,196 KB
testcase_08 AC 367 ms
75,348 KB
testcase_09 AC 365 ms
75,232 KB
testcase_10 AC 366 ms
75,508 KB
testcase_11 AC 366 ms
75,308 KB
testcase_12 AC 365 ms
75,296 KB
testcase_13 AC 363 ms
75,452 KB
testcase_14 WA -
testcase_15 AC 368 ms
75,344 KB
testcase_16 AC 366 ms
75,448 KB
testcase_17 AC 365 ms
75,524 KB
testcase_18 AC 493 ms
75,728 KB
testcase_19 AC 491 ms
75,708 KB
testcase_20 AC 496 ms
76,112 KB
testcase_21 AC 499 ms
76,144 KB
testcase_22 AC 365 ms
75,508 KB
testcase_23 AC 366 ms
75,576 KB
testcase_24 AC 484 ms
76,004 KB
testcase_25 AC 500 ms
76,044 KB
testcase_26 AC 499 ms
75,700 KB
testcase_27 AC 365 ms
75,520 KB
testcase_28 AC 365 ms
75,384 KB
testcase_29 WA -
testcase_30 AC 365 ms
75,640 KB
testcase_31 AC 364 ms
75,452 KB
testcase_32 AC 363 ms
75,336 KB
testcase_33 AC 365 ms
75,380 KB
testcase_34 WA -
testcase_35 AC 364 ms
75,344 KB
testcase_36 AC 365 ms
75,188 KB
testcase_37 AC 364 ms
75,524 KB
testcase_38 AC 496 ms
75,816 KB
testcase_39 AC 495 ms
75,880 KB
testcase_40 AC 497 ms
76,096 KB
testcase_41 AC 363 ms
75,288 KB
testcase_42 AC 495 ms
75,880 KB
testcase_43 AC 365 ms
75,344 KB
testcase_44 AC 501 ms
76,084 KB
testcase_45 AC 496 ms
76,120 KB
testcase_46 AC 366 ms
75,408 KB
testcase_47 AC 499 ms
75,884 KB
testcase_48 AC 365 ms
75,344 KB
testcase_49 WA -
testcase_50 AC 363 ms
75,372 KB
testcase_51 AC 365 ms
75,292 KB
testcase_52 AC 367 ms
75,292 KB
testcase_53 WA -
testcase_54 AC 305 ms
75,828 KB
testcase_55 AC 492 ms
76,044 KB
testcase_56 AC 365 ms
75,640 KB
testcase_57 AC 362 ms
75,188 KB
testcase_58 AC 367 ms
75,340 KB
testcase_59 AC 364 ms
75,504 KB
testcase_60 AC 368 ms
75,228 KB
testcase_61 AC 364 ms
75,644 KB
testcase_62 AC 365 ms
75,520 KB
testcase_63 AC 364 ms
75,232 KB
testcase_64 AC 366 ms
75,580 KB
testcase_65 AC 457 ms
76,028 KB
testcase_66 AC 367 ms
75,340 KB
testcase_67 AC 464 ms
75,716 KB
testcase_68 AC 366 ms
75,368 KB
testcase_69 AC 366 ms
75,320 KB
testcase_70 AC 365 ms
75,652 KB
testcase_71 AC 490 ms
76,068 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

def main():
    from sys import stdin, setrecursionlimit
    # setrecursionlimit(1000000)
    input = stdin.readline
    def iinput(): return int(input())
    def sinput(): return input().rstrip()
    def i0input(): return int(input()) - 1
    def linput(): return list(input().split())
    def liinput(): return list(map(int, input().split()))
    def miinput(): return map(int, input().split())
    def li0input(): return list(map(lambda x: int(x) - 1, input().split()))
    def mi0input(): return map(lambda x: int(x) - 1, input().split())
    INF = 1000000000000000000
    MOD = 1000000007

    T = iinput()
    X, A = miinput()
    Y, B = miinput()

    ans = INF
    for i in range(10000000):
        Z = T + B * i
        if Z >= 0:
            ans = min(ans, Z // A * X + i * Y + Z % A)
    print(ans)


main()
0