title: Character Handling and String Manipulation
body: <p>I just started learning C.
  I'm making the program below:</p>
  
  <pre><code>#include&lt;stdio.h&gt;
  #include&lt;ctype.h&gt;
  
  int main()
  {
      char s1[1000];
      char s2 [1000];
   /*    void countchar (const char * const);  */
      void reverse(const char * const);
      char manipulate (char , const char);
  
      printf ("Enter sentence number 1:\n");
  gets (s1);
  printf ("\nEnter sentence number 2:\n");
  gets (s2);
  
  printf ("\nThe two sentences entered are:\n1. %s\n2. %s\n\n", s1, s2);
  
  /*    printf ("_______________________________________\n\n");
  countchar (s1, s2);     */
  
  printf ("_______________________________________\n\n"
          "The first sentence reversed is:\n");
  reverse (s1);
  printf ("\n________________________________________\n");
  
  manipulate (s1, s2);
  
  return 0;
  }
  
  void reverse (const char * const s1Ptr)
  {
      if (s1Ptr [0] == '\0')
          return;
      else /*{
             if (isupper (s1Ptr [0]))
                  tolower (s1Ptr [0]);
                      else toupper (s1Ptr [0]);
  */
      reverse (&amp;s1Ptr[1]);
      putchar (toupper (s1Ptr [0]));
  }
  
  
  char manipulate(char s1, const char s2)
  {
  printf ("10 characters of first sentence + 10 characters of second sentence:\n%s", strncat (s1, s2, 10));
  }
  </code></pre>
  
  <p>The programs will read two sentences, then
  count the number of characters, 
  reverse the first sentence and convert all lowercase to uppercase vice versa, 
  and append 10 character from second paragraph to first one.</p>
  
  <p>The function manipulate to append the characters is not working. Can you fix it for me?
  In the function reverse, how do I convert the case vice versa? Because I can only get it from lowercase to uppercase </p>
  
  <p>The part with /* is because I don't know how to make the function. I really need help with this, please kindly point out my mistakes and help me to fix them.
  Thank you.</p>