本题的贪心技巧是,每次填坑都尽可能填最长的长度。如果下陷的深度是递减的,那么所需时间就是第一块区域所需的时间;如果递增了,那么时间再加上与前一块区域的差值。
By signing up a 虎鲸编程 universal account, you can submit code and join discussions in all online judging services provided by us.
Using your 虎鲸编程 universal account