Question: Write a C++ program and save it in a file named Problem1.cpp that reads a string sentence and replaces each occurrence of the string

Write a C++ program and save it in a file named Problem1.cpp 



Write a C++ program and save it in a file named Problem1.cpp that reads a string sentence and replaces each occurrence of the string On by no and then prints the new string. Note: the string may not have the word on in it. Sample input/output: Enter a sentence: It's ongoing and on-time It's nogoing and no-time

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!