結果
| 問題 | 
                            No.268 ラッピング(Easy)
                             | 
                    
| コンテスト | |
| ユーザー | 
                             lam6er
                         | 
                    
| 提出日時 | 2025-03-20 21:00:32 | 
| 言語 | PyPy3  (7.3.15)  | 
                    
| 結果 | 
                             
                                AC
                                 
                             
                            
                         | 
                    
| 実行時間 | 40 ms / 5,000 ms | 
| コード長 | 402 bytes | 
| コンパイル時間 | 189 ms | 
| コンパイル使用メモリ | 83,016 KB | 
| 実行使用メモリ | 53,548 KB | 
| 最終ジャッジ日時 | 2025-03-20 21:00:46 | 
| 合計ジャッジ時間 | 1,353 ms | 
| 
                            ジャッジサーバーID (参考情報)  | 
                        judge3 / judge1 | 
(要ログイン)
| ファイルパターン | 結果 | 
|---|---|
| sample | AC * 3 | 
| other | AC * 10 | 
ソースコード
from itertools import permutations
# Read input
L = list(map(int, input().split()))
R, B, Y = map(int, input().split())
min_total = float('inf')
# Try all permutations of the dimensions
for a, b, c in permutations(L):
    # Calculate the total length for this permutation
    total = 2 * (R * (a + c) + B * (a + b) + Y * (b + c))
    if total < min_total:
        min_total = total
print(min_total)
            
            
            
        
            
lam6er