#include<stdio.h>int main(){int a;scanf("%d",&a) ;if(a%2==0)printf("%d为偶数!",a);elseprintf("%d为奇数!",a);return 0;}用的是vc++
要排除零的情况吧