In some countries, it was decided to increase the retirement age starting from January , . Before this, the retirement age was years.
The increase of the retirement age is carried out as follows: the increase occurs a total of times. Each time, the retirement age is increased by months. The first increase occurs on January , , and each of the next (K-1) increases occurs months after the previous increase (N > M). For example, let M = 3. Then a citizen born on December , retires on December , , and a citizen born on January , retires on April , .
The retirement date for a given person is the earliest possible date on which the person's age is not less than the retirement age approved for that date.
To determine when a person turns years and months, you must add years and months to the date of birth, keeping the day of the month the same. If there is no such day in the calendar, the required date is the first day of the next month. Thus, if M = 3 and N = 5, those born on January , retire on May , , just like those born on February , .
Given the birth date of a citizen, you are required to determine their retirement date. It is assumed that life expectancy can be arbitrarily long.
A year is considered leap if the year number is divisible by , or is divisible by but not by .
The first line contains three integers , , and (0 < M \leq 12, M < N \leq 24, 0 \leq K \leq 60). The second line contains the citizen's date of birth in the format "DD.MM.YYYY" (i.e., day, month, and year without quotes and with a leading zero for numbers less than ).
All dates are between and .
Print the citizen's retirement date in the same format as the input date.
Example 1