Recently I started solving dp questions at lightoj ,but was unable to come up with a solution for the problem . Link:
The question is as follows.You would be provided with k identical mailbox prototypes each fitting up to m fire-crackers with following constraints
1.If you blow up a mailbox, you can’t use the mailbox again.
2.If a mailbox can withstand x fire-crackers, it can also withstand x-1 fire-crackers.
3 Upon an explosion, a mailbox is either totally destroyed (blown up) or unharmed, which means that it can be reused in another test explosion.
we are asked to find the minimum number of fire-crackers we need to buy to test the mailboxes.