A TV show has a time slot (say k mins) for ads. Many advertisers bid for that slot (e.g. 8 / 8 mins show 5 mins, cost will be 8/8*5 = $5)
Each ads need to show at least half of the bit time.(e.g. 9 mins ads need at least 4 mins)
Ads bid brfore the time slot starts and data is stored in B[N].
How to get the maximum revenue?