Question: Write a C++ function called reverse that takes in a string and returns its reverse - input: top output: pot Write a second C++ function

 Write a C++ function called reverse that takes in a string

Write a C++ function called reverse that takes in a string and returns its reverse - input: "top" output: "pot" Write a second C++ function called join that takes in two strings and reverse(or any other function), and returns a joined string of the reverse of the two inputted strings (or just whatever the function does). Pseudocode def join(string1, string2, function) return function(string1) + function(string2) input: "rob", "got", reverse output: "bortog" Use C++'s "std::function" to declare any functions

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 Databases Questions!