There are
numBottles
water bottles that are initially full of water. You can exchangenumExchange
empty water bottles from the market with one full water bottle.The operation of drinking a full water bottle turns it into an empty bottle.
Given the two integers
numBottles
andnumExchange
, return the maximum number of water bottles you can drink.
1 | class Solution { |