eolymp
bolt
Try our new interface for solving problems
Problems

Birthday

Birthday

Given day and month of birth, and the current day, month and year. Determine how many days are left before the birthday. \InputFile In the first row are separated by spaces the day and month of birth, the second - separated by spaces the current day, month and year. Year from \textbf{1920} to \textbf{3000}, a month - from \textbf{1} to \textbf{12}, day - \textbf{1} to the number of days per month. \OutputFile Deduce the number of days remaining until the birth.
Time limit 1 second
Memory limit 64 MiB
Input example #1
19 04
19 04 2002
Output example #1
0

Example description: Leap years - those numbers are divisible by 400, as well as the number is divisible by 4 but not divisible by 100.