USACO Gold

寫出來會很清楚的看見

Minimum cost =

C1Y1 + Y2 * min(C1 + S, C2) + Y3 * min(C3, S + min(C1 + S, C2) ) ...

所以可以發現前項的minimum是可以被繼承的

 

http://nopaste.csie.org/be01d

文章標籤
全站熱搜
創作者介紹
創作者 robertanders 的頭像
robertanders

Robert Anderson's Blog

robertanders 發表在 痞客邦 留言(0) 人氣(0)