Question: Strings itemOfInterest and inputltem are read from input. Integer wordCount is initialized with 1. Write a while loop that iterates until inputltem is equal
Strings itemOfInterest and inputltem are read from input. Integer wordCount is initialized with 1. Write a while loop that iterates until inputltem is equal to "Finale". In each iteration of the loop: Increment wordCount if inputltem is equal to itemOfInterest. Read string inputltem from input. Click here for example Note: Assume that input has at least two strings. 1 #include 2 using namespace std; FE NM & in 1000 3 4 int main() { 5 6 string inputItem; 7 int wordCount; 8 9 cin >> itemOf Interest; 10 cin >>inputItem; 11 string itemOf Interest; 12 wordCount = 1; 13 14 /* Your code goes here */ 15 in 201 16 17 cout < itemOf Interest < < occurs. < < wordCount < < time(s)." < < endl; FF 1 FF 2 3 L 18 19} Check return 0; Next level 2 3
Step by Step Solution
There are 3 Steps involved in it
To fulfill the given requirements you need to create a while loop that continues to re... View full answer
Get step-by-step solutions from verified subject matter experts
