#include<stdio.h>
int main()
{
int x;
printf("请输入年份\n");
scanf("%d",&x);
if((x%4==0&&x%100!=0)||x%400==0)
{
printf("%d年是闰年",x);
}
else
{
printf("%d年不是闰年",x);
}
return 0;
}
#include<stdio.h>
int main()
{
int x;
printf("请输入年份\n");
scanf("%d",&x);
if((x%4==0&&x%100!=0)||x%400==0)
{
printf("%d年是闰年",x);
}
else
{
printf("%d年不是闰年",x);
}
return 0;
}