Question: The Programming Language to be used is C++ Problem 4- Simple sentence manipulation (10 points) Write a program that reads a sentence that ends with

The Programming Language to be used is C++
Problem 4- Simple sentence manipulation (10 points) Write a program that reads a sentence that ends with a period. The sentence should have plus symbols wherever you would expect there to be spaces. It outputs the sentence with all 'e' letters replaced by and all plus symbols are replaced by spaces. Here is an example (user input has been underlined): Please enter a sentence ending with a period: Hello +my+nametistGeorae. H*llo, my nam* is G*org*. HINTS: The key to doing this is making good use of the cin buffer. Essetially you want to do the following loop: do f read one letter off the cin buffer print the letter (maybe altered, e.g. e->*) while (you haven't seen the period); Remember that as soon as the program displays "Please enter a sentence ending with a period", the user types their sentence and hits enter. This means that: All the letters they have typed are sitting on the cin buffer waiting to be used All the letters that you print will automatically go on the next line (since the user hit enter after typing his/her sentence)
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
