P5716 [Shenji 3. Example 9] Number of Days in a Month
Description
Given a year and a month, output how many days there are in that month of that year. Leap years must be considered.
Input Format
Input two positive integers, representing the year $y$ and the month $m$, separated by a space.
Output Format
Output one line containing one positive integer, indicating how many days there are in that month.
Explanation/Hint
Constraints: $1583 \leq y \leq 2020$, $1 \leq m \leq 12$.
Translated by ChatGPT 5