Answer to Question #33572 in C++ for Bob

Question #33572
Write a recursive function void reverse() that reverses a sentence.
For example:

Sentence greeting = new Sentence("Hello!")
Greeting reverse(),
cout « greeting.get_text() «"\n";

Prints the string "!olleH". Implement a recursive solution by removing the first character, reversing a sentence consisting of the remaining text, and combining the two.
0
Expert's answer

Answer in progress...

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Comments

No comments. Be the first!

Leave a comment

LATEST TUTORIALS
APPROVED BY CLIENTS