/* Title Description: Compile a program, read the user input, to "." The end of a line of text, counting the total number of words, and separately output each word contains how many characters. (any part separated by one or more spaces is a single word) input: The input includes 1 lines of string, with "." Ends with multiple words in the string, separated by one or more spaces between the words. Output: There may be more than one set of test data, and for each set of data, the number of letters contained in each word in the output string. Sample input: Hello how is you. Sample output: 5 3 3 3*/# include <stdio.h># include <string.h>int main (void) {int i,j,k = 0,n,len , Count,a[20];char s[100];scanf ("%d", &n); for (i = 0; i < n; i++) {GetChar (); Absorbs the carriage return character. if (n <= 0) break;gets (s); len = strlen (s); for (j = 0,count = 0; J < Len; J + +) {if ((s[j]! = ') && (s[j]! = '. ' ) {count++;continue;} A[k] = count;k++;if (s[j] = = '. ') Break;count = 0;} for (i = 0; i < K; i++) {if (a[i]! = 0) printf ("%d", A[i]);} printf ("\ n");} return 0;}
1182 Statistical words