[Email protected]:~/bowl/shangdongoj$ cat gaiju.c/* String Word initial capitalization, and will be the largest delete. * Limit letter string within ..... */#include <stdio.h>void Rmchar (char revise[]), void Delchar (char delete[]); int main (void) {char strchar[50] = {' '};//scanf ('%s ', strchar);//cannot enter a string with spaces ... Gets (Strchar); Rmchar (Strchar);d Elchar (Strchar);p rintf ("%s\n", Strchar); return 0;} /* Change the initial letter to uppercase */void Rmchar (char revise[]) {int i = 0;for (i=0;revise[i]!= '; i++ ') {if (i==0&&revise[i]>96| | i>0&&revise[i-1]== "&&revise[i]>96) revise[i]-= 32;}} /* Delete the first letter of the largest word */void Delchar (char delete[]) {char *q = Null;char *p = Delete;char top = ' A '; for (; *p!= '; *p++) {if (*p>40& Amp;&*p<=90&&*p>top) {top = *p;q = P;}} for (p=q;*p!= "; *p++); for (; *p=="; *p++); for (; *p!= '); *p++,*q++) {*q = *p;} *q = ' + ';} [Email protected]:~/bowl/shangdongoj$
Letters, strings