結果

問題 No.2227 King Kraken's Attack
ユーザー qibqib
提出日時 2023-04-20 20:39:17
言語 PyPy3
(7.3.15)
結果
WA  
実行時間 -
コード長 330 bytes
コンパイル時間 190 ms
コンパイル使用メモリ 82,176 KB
実行使用メモリ 67,712 KB
最終ジャッジ日時 2024-04-23 15:47:56
合計ジャッジ時間 4,353 ms
ジャッジサーバーID
(参考情報)
judge5 / judge4
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 41 ms
51,840 KB
testcase_01 AC 41 ms
52,096 KB
testcase_02 AC 40 ms
51,584 KB
testcase_03 AC 51 ms
59,520 KB
testcase_04 AC 43 ms
51,840 KB
testcase_05 AC 40 ms
51,968 KB
testcase_06 AC 45 ms
52,736 KB
testcase_07 AC 43 ms
53,248 KB
testcase_08 AC 43 ms
52,864 KB
testcase_09 AC 48 ms
53,632 KB
testcase_10 AC 43 ms
52,992 KB
testcase_11 AC 45 ms
53,248 KB
testcase_12 AC 44 ms
53,376 KB
testcase_13 AC 44 ms
52,864 KB
testcase_14 AC 56 ms
58,880 KB
testcase_15 AC 55 ms
59,392 KB
testcase_16 AC 68 ms
59,392 KB
testcase_17 AC 68 ms
61,056 KB
testcase_18 AC 54 ms
58,368 KB
testcase_19 AC 70 ms
61,824 KB
testcase_20 AC 70 ms
62,208 KB
testcase_21 AC 78 ms
63,488 KB
testcase_22 AC 50 ms
58,624 KB
testcase_23 AC 49 ms
59,264 KB
testcase_24 AC 73 ms
64,000 KB
testcase_25 AC 56 ms
59,136 KB
testcase_26 AC 54 ms
59,392 KB
testcase_27 AC 60 ms
60,544 KB
testcase_28 AC 80 ms
65,152 KB
testcase_29 AC 82 ms
64,768 KB
testcase_30 AC 95 ms
67,712 KB
testcase_31 AC 81 ms
65,152 KB
testcase_32 AC 76 ms
65,024 KB
testcase_33 AC 75 ms
65,024 KB
testcase_34 AC 70 ms
65,024 KB
testcase_35 AC 76 ms
65,536 KB
testcase_36 AC 67 ms
63,488 KB
testcase_37 AC 48 ms
58,880 KB
testcase_38 AC 50 ms
58,752 KB
testcase_39 AC 51 ms
58,752 KB
testcase_40 AC 49 ms
58,880 KB
testcase_41 AC 54 ms
58,880 KB
testcase_42 AC 50 ms
58,880 KB
testcase_43 AC 49 ms
59,136 KB
testcase_44 AC 53 ms
59,008 KB
testcase_45 WA -
権限があれば一括ダウンロードができます

ソースコード

diff #

h, w, la, lb, ka, kb = map(int, input().split())

ans = 1 << 60
b = 0
for a in range(h, -1, -1):
  while b < w:
    cnt = min(h, a * la) * min(w, b * lb) + a * ka + b * kb
    if cnt >= h * w:
      break
    b += 1
  cnt = min(h, a * la) * min(w, b * lb) + a * ka + b * kb
  if cnt >= h * w:
    ans = min(ans, a + b)

print(ans)
0