HBC24985[网络流24题]深海机器人问题[USACO 2008 Nov G]Toys题解

三分之二給你 算法基础篇 49 0
挑战自我,勇攀编程高峰!全网最全C++题库,助您成为编程达人。
Bessie's birthday is coming up, and she wishes to celebrate for the next D (1

Bessie's birthday is coming up, and she wishes to celebrate for the next D (1 <= D <= 100,000; 70% of testdata has 1 <= D <= 500) days. Cows have short attention spans so Bessie wants to provide toys to entertain them. She has calculated that she will require Ti (1 <= Ti <= 50) toys on day i. Bessie's kindergarten provides many services to its aspiring bovine programmers, including a toy shop which sells toys for Tc (1 <= Tc <= 60) dollars. Bessie wishes to save money by reusing toys, but Farmer John is worried about transmitting diseases and requires toys to be disinfected before use. (The toy shop disinfects the toys when it sells them.) The two disinfectant services near the farm provide handy complete services. The first one charges C1 dollars and requires N1 nights to complete; the second charges C2 dollars and requires N2 nights to complete (1 <= N1 <= D; 1 <= N2 <= D; 1 <= C1 <= 60; 1 <= C2 <= 60). Bessie takes the toys to the disinfecters after the party and can pay and pick them back up the next morning if one night service is rendered, or on later mornings if more nights are required for disinfecting. Being an educated cow, Bessie has already learned the value of saving her money. Help her find the cheapest way she can provide toys for her party. POINTS: 400

HBC24985[网络流24题]深海机器人问题[USACO 2008 Nov G]Toys题解
-第1张图片-东莞河马信息技术
(图片来源网络,侵删)
不断学习,不断挑战,才能在编程领域中脱颖而出!全网最全C++题库,助您成为编程高手!

标签: HBC24985[网络流24题]深海机器人问题[USACO 2008 Nov G]Toys题解