This program is all about finding how many times a character comes in a string. In the program there is a count variable which will be incremented if the same character appears again and then that count variable will be printed.
printf("Enter any string ");
printf("Enter any character whose frequency u want to find: ");
// comparing string with the character whose frequency we want to find.
// increment the count variable if the same character repeated.
printf("Frequency of %c = %d", char, count); // printing the frequency of the character.
Enter a string: Welcome to Findnerd.
Enter a character to find frequency: e
Frequency of e = 3