Clocks#111

Clocks

1 second
64 megabytes
Easy

A striking clock chimes a number of times equal to the hour shown on the dial (from to ) at each full hour. Additionally, it chimes once each time the minute hand points to .

Input

The input contains the start and end times within a single calendar day. Each time is given as hours () and minutes (), separated by a space (0 \leq H \leq 23, 0 \leq M \leq 59).

Output

Output the total number of chimes in the specified interval.

Examples

Example 1

Loading
Loading