?? 2-6.c
字號(hào):
#include<stdio.h>
void main(void)
{
char c;
int alpha,digit,other;
alpha=digit=other=0;
printf("input a text end of newline:\n");
while((c=getchar())!='\n')
if(c>='a'&&c<='z'||c>='A'&&c<='Z')
alpha++;
else if (c>='0'&&c<='9')
digit++;
else
other++;
printf("alphas=%d\ndigits=%d\nother=%d\n",alpha,digit,other);
}
?? 快捷鍵說明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號(hào)
Ctrl + =
減小字號(hào)
Ctrl + -