#T645. 昆虫繁殖
昆虫繁殖
Description
Scientists have discovered a special insect in tropical forests with strong reproductive capabilities. Each pair of adult insects produces y pairs of eggs every x months, and each pair of eggs takes two months to mature into adults. Assuming no adult dies, there is only one pair of adults in the first month, and adults do not lay eggs in the first month after maturing (they start laying eggs after x months). How many pairs of adults will there be after z months?
Input Format
The input consists of only one line with three positive integers: x y z
Output Format
The output consists of only one line, representing the number of adult pairs after z months (note: this refers to the count at the end of the z-th month, i.e., the number at the beginning of the (z+1)-th month).
【Data Range】
X ≥ 0, Y ≥ 0, Z ≥ X
Source
CodesOnline