Write a Program to enter string and find the number of occurrence of any word.
Answers
Answered by
0
First, we split the string by spaces in a.
Then, take a variable count = 0 and in every true condition we increment the count by 1.
Now run a loop at 0 to length of string and check if our string is equal to the word.
Similar questions