I need help with menu creation and character manipulation within the string

Write a function that displays the following menu, reads the selection made and returns the selection as an integer.
Write a C++ program that repeatedly asks for and gets a string from the user and presents the following menu of operations on the string using the above menu function until the user chooses to exit:
1. Search for a character in the string
2. Change a character within the string
3. Display the first n characters of the string
4. Display the last n character of the string
5. Display all characters that lie between two given indices
6. Null the string
7. Exit

Please enter a string: My roommate is not home right now.
Make a selection:

1. Search for a character in the string
2. Change a character within the string
3. Display the first n characters of the string
4. Display the last n character of the string
5. Display all characters that lie between two given indices
6. Null the string
7. Exit
Choice: 1
I have the impression this is an assignment for class.

I would start with http://www.cplusplus.com/doc/ for tutorials for this basic stuff.

Things you might look into is cout or a basic hello world tutorial for a starting point, then I would read up on functions.
Topic archived. No new replies allowed.