by Dinesh Thakur

 
#include <stdio.h>
#include <conio.h>
#include <string.h>
void main(void)
  {
    int ctr = 0;
    char string[] = "this is a test";
    clrscr();
    printf("This is the string: \"%s\"\n", string);
    printf("Press any key to continue."); while (!kbhit());
    for(ctr = 0; ctr < strlen(string); ctr++)
      {
            if (ctr == 0)
              string[ctr] = toupper(string[ctr]);
            if (string[ctr] == ' ')
              string[ctr + 1] = toupper(string[ctr + 1]);
      }
    printf("\n\nThis is the new string: \"%s\".", string);
    getch();
  }


Convert the First Char of Every Word into Uppercase