結果

問題 No.453 製薬会社
ユーザー H3PO4H3PO4
提出日時 2020-08-29 00:12:04
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
TLE  
(最新)
AC  
(最初)
実行時間 -
コード長 346 bytes
コンパイル時間 497 ms
コンパイル使用メモリ 12,672 KB
実行使用メモリ 126,004 KB
最終ジャッジ日時 2024-04-26 15:13:00
合計ジャッジ時間 6,920 ms
ジャッジサーバーID
(参考情報)
judge3 / judge5
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 TLE -
testcase_01 AC 1,336 ms
68,624 KB
testcase_02 AC 1,337 ms
68,752 KB
testcase_03 AC 1,320 ms
69,496 KB
testcase_04 AC 1,326 ms
69,372 KB
testcase_05 AC 1,334 ms
68,756 KB
testcase_06 AC 1,386 ms
69,124 KB
testcase_07 AC 1,333 ms
69,104 KB
testcase_08 AC 1,351 ms
69,352 KB
testcase_09 AC 1,349 ms
69,136 KB
testcase_10 AC 1,330 ms
69,096 KB
testcase_11 AC 1,452 ms
69,328 KB
testcase_12 AC 1,606 ms
126,004 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

from scipy.optimize import linprog

# linprogはminimizeを計算するので金額を負値にする
c = [-1000, -2000]
A = [[3 / 4, 2 / 7], [1 / 4, 5 / 7]]
B = list(map(int, input().split()))
bounds = [(0, None), (0, None)]

res = linprog(c, A_ub=A, b_ub=B, bounds=bounds, method='revised simplex', options={'autoscale': True})
print(-res.fun)
0