1-1字符判断
#include<stdio.h> int main() { char c; scanf("%c",&c); if(c>='a'&&c<='z') { c=c-32; printf("%c\n",c); } else if(c>='A'&&c<='Z') { c=c+32; printf("%c\n",c); } else if(c>=0&&c<=9) { c=c; printf("%c\n",c); } else if(c==' ') { printf("space\n"); } else { printf("other\n"); } return 0; }