Tanya decided to call her friend, but remembered that she lives very far away, so it may be too late or early in her friend's time zone. Tanya's clock shows exactly H hours, Tanya lives in the time zone with them UTC + A, and her friend – in the UTC+B time zone. Help Tanya determine the time in her friend's time zone at this moment.
The program receives as input three integers H, A and B, 0 ≤ H≤ 23, ?11 ? A≤ 12, −11≤ B≤ 12.
In the UTC+A time zone, the local time is greater than the time in the UTC+0 time zone by A hours (if A < 0, then |A| hours less). For example, if it is 12 o'clock in the UTC+0 time zone, then in the UTC+1 time zone – 13 hours, and in the time zone UTC−1 – 11 o'clock.
The program should output a single number – time (number of hours) in the girlfriend's time zone.
Time in this task means the number of hours that can take values from 0 to 23. When solving the problem, please note that in the friend time zone there may already be the next date or the previous date, the program should display the number of hours on the friend's watch in this moment, that is, a number from 0 to 23.
Examples
# |
Input |
Output |
Explanation |
1 |
15
3
-5 |
7 |
Tanya's – 15 hours, she lives in the UTC + 3 time zone. In the hour
UTC+0 is now 12 o'clock. Girlfriend lives in UTC−5,
and it's 7 o'clock now.
|