結果
問題 | No.27 板の準備 |
ユーザー |
|
提出日時 | 2021-12-31 11:30:20 |
言語 | PyPy3 (7.3.15) |
結果 |
AC
|
実行時間 | 113 ms / 5,000 ms |
コード長 | 537 bytes |
コンパイル時間 | 281 ms |
コンパイル使用メモリ | 81,784 KB |
実行使用メモリ | 76,400 KB |
最終ジャッジ日時 | 2024-10-08 03:45:45 |
合計ジャッジ時間 | 3,117 ms |
ジャッジサーバーID (参考情報) |
judge3 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 18 |
ソースコード
V = list(map(int,input().split()))ans = sum(V)M = 31for i in range(1,M):for j in range(1,M):for k in range(1,M):cost = [1000]*Mcost[0] = 0for t in ((i,j,k)):for l in range(M):if cost[l] == 1000:continueif l+t < M:cost[l+t] = min(cost[l+t],cost[l]+1)count = 0for v in V:count += cost[v]ans = min(ans,count)print(ans)