Suppose we can buy a chocolate bar from the vending machine for $1 each.Inside every chocolate bar is a coupon. We can redeem six coupons for onechocolate bar from the machine. This means that once you have startedbuying chocolate bars from the machine, you always have some coupons.We would like to know how many chocolate bars can be eaten if we startwith N dollars and always redeem coupons if we have enough for an additional chocolate bar.For example, with 6 dollars we could consume 7 chocolate bars afterpurchasing 6 bars giving us 6 coupons and then redeeming the 6 couponsfor one bar. This would leave us with one extra coupon. For 11 dollars, wecould have consumed 13 chocolate bars and still have one coupon left.For 12 dollars, we could have consumed 14 chocolate bars and have twocoupons left.
Suppose we can buy a chocolate bar from the vending machine for $1 each.
Inside every chocolate bar is a coupon. We can redeem six coupons for one
chocolate bar from the machine. This means that once you have started
buying chocolate bars from the machine, you always have some coupons.
We would like to know how many chocolate bars can be eaten if we start
with N dollars and always redeem coupons if we have enough for an additional chocolate bar.
For example, with 6 dollars we could consume 7 chocolate bars after
purchasing 6 bars giving us 6 coupons and then redeeming the 6 coupons
for one bar. This would leave us with one extra coupon. For 11 dollars, we
could have consumed 13 chocolate bars and still have one coupon left.
For 12 dollars, we could have consumed 14 chocolate bars and have two
coupons left.

Trending now
This is a popular solution!
Step by step
Solved in 3 steps with 1 images









