// year 年份(四位数)
// month 月份(从1开始)
public
static
int
getMonthDays(
int
year,
int
month) {
if
(month ==
2
) {
if
((year %
4
==
0
&& year %
100
!=
0
) || (year %
400
==
0
)) {
return
29
;
}
else
{
return
28
;
}