Skip to content
Get started

Ways to make a dollar

In how many ways can you make 100100 cents from coins worth 1,5,101, 5, 10 and 2525 cents, if only the multiset of coins matters (the order in which coins are laid down is irrelevant)?

Show hints (2)+
  1. Fix the number of quarters, then the number of dimes; nickels and pennies are then easy.
  2. In the DP, which loop must be outside so that 1+5 and 5+1 count once?

Answer

Reveal answer →

242

Create a free account to see the full worked solution and track your progress.

Interview format: Prop Trading

Related questions