Hey I'm building this program to take the user's input and produce 1.The entered Data 2.The string in lower case. 3.the string in upper case. 4. the string with the first letter of each word capitalized. 5. the string in camel case.

I have everything running smooth except for camel case at the end. Please can someone help me code the end? I'd appreciate it a lot!

Code:
#include <stdio.h>
#include <stdio.h>
#include <stdlib.h>
#include <ctype.h>

void toUpper(char *str);
void toLower(char *str);
void toFirstCap(char *str);
void toCamelCase(char *str);

int main(int argc, char **argv)
{
 char sentence[256];
 char ch; 
 int i = 0;


printf("Enter a string: ");
gets(sentence);

printf("\nYour Sentence:%s\n",sentence);
toLower(sentence);

printf("\nLower case:%s\n",sentence);
toUpper(sentence);

printf("\nUpper case: %s\n",sentence);
toFirstCap(sentence);

printf("\nFirstCap case: %s\n",sentence);
toFirstCap(sentence);


//printf("\nCamel case: %s\n",sentence);
//toCamelcase(sentence);


system("pause");}



void toUpper(char *str)
 {
  while(*str != '\0')
   {
   if(*str >= 'a' && *str <= 'z')
    { 
     *str -= 'd' - 'D';
    } 
   str++; 
   }  
 }



void chngCaseSingleCharacter(char *str, int cAse)
 {
 if(cAse == 2)
 {
  if(*str >= 'a' && *str <= 'z')
  {
   *str -= 'd' - 'D';}
   else if(cAse == 1)
    {
     if(*str >= 'A' && *str <= 'Z')
      {
       *str += 'd' - 'D';
    }}
}}



void toLower(char *str)
 {
  while(*str != '\0')
 {
   if(*str >= 'A' && *str <= 'Z')
    { 
     *str += 'd' - 'D';
    } 
   str++; 
  }
 }



void chngCasesingleCharacter(char *str, int cAse)
 {
 if(cAse == 2)
 {
  if(*str >= 'a' && *str <= 'z')
   {
    *str -= 'd' - 'D';
   }
  else if(cAse == 1)
   {
    if(*str >= 'A' && *str <= 'Z')
      {
       *str += 'd' - 'D';
   }}
}}



void toFirstCap(char *str)
{
 char b;
  while( (b = *str++) != '\0')
   {
   if(b == ' ' || b == '\t')
    {
    if(*str >= 'a' && *str <= 'z')
    { 
     *str -= 'd' - 'D'; 
    }
    }
   else
    {
     if(*str >= 'A' && *str <= 'Z') 
      {
       *str += 'd' - 'D'; 
    }}
}}



void toFirstCapSmartWay(char *str)
 {
  char b; 
  while( (b = *str++) != '\0')
   { 
    if(b == ' ' || b == '\t') 
   {
     chngCaseSingleCharacter(str, 2);
   }
    else 
     {
      chngCaseSingleCharacter(str, 1);
     }
   }   
 }

//void toCamelCase(char *str)
//put code 4 camel case here//