Griffy has arrived at Don Mills, but he's too early and there's no one at the school to help him with his coding! He decides to wait until school starts so he can get some pointers (see what we did there?). Given the time he arrives at and the time that school starts, determine how many seconds Griffy will need to wait.
Input Specification
All times will be given in the format HH:MM:SS
.
First line: Time Griffy arrives (time will be less than 12:00:00
).
Second line: Time school starts (time will be less than or equal to 23:59:59
).
Note: The time school starts will be strictly greater than the time Griffy arrives.
Output Specification
One line, the number of seconds Griffy will need to wait.
Sample Input
08:15:00
08:30:00
Sample Output
900
Comments
The problem mentions
23:59:59
, but leap seconds can cause the last number to go up to61
.But since we explicitly state the constraint up to 23:59:59, we don't consider leap seconds.