紅色是幫你改的喔
#include <stdio.h>
int main()
{
int a, b, c, d;
while(scanf("%d", &a) == 1)
b=a%4;
c=a%400;
d=a%100;
if(b==0 && d!=0 || c==0)
printf("閏年\n");
else
printf("平年\n");
}
return 0;