Thanks for the responses but that was not exactly what I was looking for.
First of all I use Borland C++ 3.1 and this program is running under DOS.

So I'll write again my problem....

Program Starts
1st String is defined as
input01[255]
2nd String is defined as
input02[255]

then the program asks to enter the 1st String then the Second string.

Afterwards a menu appears, which works with switch.

So here are my questions:
1. If you enter the 1st Menu point, you'll be asked for which character to search.

i.g.:
Enter Char to Search: 'a'

then this character is counted in the String. For example the first String was. "A Apple a day keeps the doctor away" Second string was "Another day in paradise".

Then something like this should appear

First String : 6
Second String: 4

I've tried this many times with assigning a pointer but it didn't work.
Also upper and lowercase should be considered.

2nd Question: How can I count the words, I've tried it several times with 'strtok' but had no success. So if you enter this menu. Something like this should appear. Consider again the Strings above given.

First String: 8
Second String: 4

3rd and last question:
If you enter the 3rd Menu you'll be asked for to enter a word to be searched. For example this should work like this. again conisdering the strings above given.

Enter Word to Search: Apple

1st String: Found
2nd String: Not Found

I've tried this also with strstr but it didn't work.

As an example the program will look like this.

Code:
#include<stdio.h>
#include<conio.h>
#include<string.h>
main()
{  
   char input01[255], input02[255], char01, string01;  
   int i = 0, choice;  

   printf("\nEnter First String: ");  
   gets(input01);  
   printf("Enter Second String : ");  
   gets(input02);  

   while(i == 0)       
           {        
              printf("Please Choose\n");        
              printf("1. Count Character\n");        
              printf("2. Word Count\n");        
              printf("3. Search for a Word\n");        
              printf("4. Exit\n");       
              printf("Your choice: ");        
              scanf("%d", &choice);        

              switch(choice)              
                        {               
                            case 1 : clrscr();                        
                                          printf("Enter the Char to Search: ");
                                          scanf("%c", char01);
                                          ????????
                                          break;               
                            case 2 :  clrscr();
                                           printf("WORD COUNT\n\n"); 
                                           ????????? 
                                           break;               
                            case 3 :  printf("Enter Word to Search in String: ");                        
                                           gets(string01);                        
                                           ?????????
                                           break;               
                                           case 4 : i = 1;                        
                                           break;             
                        }
}
It should be something like this, so I actually don't need the creme-a-la-creme of the codes, just a simples one do this functions.


with my best reagrds... Special Thanks to Lynux_Penguen and Hammer