### tinymon's blog

By tinymon, 5 weeks ago, ,

Hi, I am new to codeforces :D

I was trying this problem, and I have a doubt in the editorial given here.

How do we represent the function F without the parameter H? We cannot create a DP table if H was there as it would be too large. Also, H has to be a part of the function somehow. Can anyone explain how to maintain that constraint?

Thanks for any help!

 » 5 weeks ago, # |   0 Then the solution to our problem is just the maximum f(C) for all C where the sum of all the heights of cows in C is at least H.
•  » » 5 weeks ago, # ^ |   0 -,- read that. but how do i check for that H?
•  » » » 5 weeks ago, # ^ |   0 Let S(C) be the .Let then S(C) = S(C - c) + Hc.