I found a mathematical riddle which I solved by experiment and I would like to know is there a formula of some sort to solve these kind of problems.
You have 10 Euro. You can buy a bottle of beer for 1 Euro. You can exchange 2 empty bottles for 1 new full bottle. What is the maximum number of bottles that you can go through for your 10 Euro ?
By experiment you can go through 19 bottles for the 10 Euro.
But is there some formula to obtain 19 from the initial conditions ? I thought maybe something related to sequences or some kind of limit.
Any ideas?
With $n$ € you can get $2n-1$ beers.
So you have exchanged $(n-1)$ empty bottles for $(n-1)$ beers, hence you had $n+(n-1)=2n-1$ beers and one empty bottle remains.