70,035
社区成员
发帖
与我相关
我的任务
分享#include <stdio.h>
int main()
{
#if 1
int cnt = 0;
char t;
while (scanf("%c", &t) == 1 && t != '.') {
cnt++;
if (t == ' ') {
printf("%d\n", cnt);
cnt = 0;
}
}
printf("%d\n", cnt);
#else
char t=' ';
while(t != '.'){
int cnt=0;
while(t != ' '){
cnt++;
scanf("%c", &t);
if(t=='.'){
printf("%d\n",cnt);
goto out;
}
}
printf("++%d\n",cnt);
scanf("%c", &t);
}
out:
#endif
return 0;
}scanf("%s",&t);scanf("%c",&t);int scanf(const char* format, argument);scanf("%s",&t);scanf("%c",&t);scanf("%s",t);scanf("%s",&t);
char t[32] = '0';