answersLogoWhite

0


Best Answer

unsigned find (const char* str, char c) {

unsigned total;

total = 0;

if (str!=NULL) while (*str) {

if (*str++==c) ++total;

}

return total;

}

User Avatar

Wiki User

5y ago
This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: Write a C program to find occurrences of given character in a sentences?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Related questions

Write a program to enter a character and it will tell the character etered?

{char a;...cout > a;cout


How do you write a program that removes all occurrences of a given X in a given sequence of numbers?

You do nothing! A sequence of numbers will contain no X and so nothing needs doing!


What sentences in a write jungle sentences homework do you write?

Write a very good thing over anything


Write a program in c language to implement framing methods like character stuffing?

A program in c language to implement framing methods like character stuffing can be grave sizeCRC-32 and the variable c50.


Write sentences on which?

This is a program to which I belong.I don't know which kind of pie to order.My classes, which ended last Friday, will start again in six weeks.


What should you do if he hate you?

Learn to write sentences, guys hate girls who can't spell or write sentences.


How do you write Two sentences that have nouns that are preceded by at least two modifiers?

write two sentences to have noun


Can kindergardeners write sentences?

yes they can it's just that there kindergarden sentences


Write a C program to find out whether character passes through keybroad is a digit or not?

hey..it s simple..make use of built-in function isdigit(character)..it s in stdlib.h...


How do you write a contradicting sentence using an apostrophe?

Doesn't the school require students to write their own sentences?A stranger's sentences won't match what the person can create alone.Alas, one girl couldn't write sentences, and one boy wouldn't.


Why use simple sentences?

Simple sentences are easier to understand. They are easy to translate. They are easier to write than complex sentences.


How do you write e in carsive in sentences?

hello