Write a program which calculates the total seconds between two input dates.
Both the start date and the end date are included in the calculation.
Three criteria must be taken into account to identify leap years:
(1) The year can be evenly divided by 4; (2) If the year can be evenly divided by 100, it is NOT a leap year, unless; (3) The year is also evenly divisible by 400. Then it is a leap year.
input error checking:
(1) year, month, and day should all be at least 1 (2) month is between 1 ~ 12 (3) the date of a month should be valid (4) only leap year can have Feb 29 (5) the end date cannot be earlier than the start date