結果
| 問題 | 
                            No.268 ラッピング(Easy)
                             | 
                    
| コンテスト | |
| ユーザー | 
                             | 
                    
| 提出日時 | 2017-02-02 18:20:20 | 
| 言語 | Python3  (3.13.1 + numpy 2.2.1 + scipy 1.14.1)  | 
                    
| 結果 | 
                             
                                AC
                                 
                             
                            
                         | 
                    
| 実行時間 | 37 ms / 5,000 ms | 
| コード長 | 556 bytes | 
| コンパイル時間 | 111 ms | 
| コンパイル使用メモリ | 12,672 KB | 
| 実行使用メモリ | 10,752 KB | 
| 最終ジャッジ日時 | 2024-12-24 03:55:04 | 
| 合計ジャッジ時間 | 1,310 ms | 
| 
                            ジャッジサーバーID (参考情報)  | 
                        judge5 / judge2 | 
(要ログイン)
| ファイルパターン | 結果 | 
|---|---|
| sample | AC * 3 | 
| other | AC * 10 | 
ソースコード
import sys
from itertools import permutations
def debug(x, table):
    for name, val in table.items():
        if x is val:
            print('DEBUG:{} -> {}'.format(name, val), file=sys.stderr)
            return None
def solve():
    L1, L2, L3 = map(int, input().split())
    R, B, Y = map(int, input().split())
    isshu = [2*(L1+L2), 2*(L2+L3), 2*(L3+L1)]
    ans = float('inf')
    for i, j, k in permutations((0,1,2)):
        ans = min(ans, isshu[i]*R + isshu[j]*B + isshu[k]*Y)
    print(ans)
    pass
if __name__ == '__main__':
    solve()