原题题目
代码实现(首刷自解)
class Solution {
public:int numWaterBottles(int numBottles, int numExchange) {
int ret = numBottles,empty = numBottles;while(empty >= numExchange){
int temp = empty/numExchange;ret += temp;empty -= (numExchange-1)*temp;}return ret;}
};