一瓶啤酒售價$2,兩個空瓶換一瓶,四個瓶蓋\送一瓶。$10共可以喝幾瓶? beer $2 each A bottle of beer costs $2. Two empty bottles: get one bottle for free Four bottle caps : get one bottle for free How many bottles can you have if you have $10? 2 empty bottles: get 1 bottle free 4 crown caps: get 1 bottle free I have $10 beer bottle cap 5 5b 5c total = ... while(尚有酒送 free bottles){ nfree = ... // 送nfree瓶 cap = ... // 尚餘瓶蓋 bot = ... // 尚餘空瓶 total = ... // 目前共喝了total瓶 } total no.of bottles 共喝了??瓶