Casel: Write a menu driven program that allows you to visit cities of man in random order with following options. 1: Visit a city 2: Go to previous city 3: Quit the program When user presses 1:...


Casel: Write a menu driven program that allows you to visit cities of
man in random order with following options.
1: Visit a city
2: Go to previous city
3: Quit the
program
When user presses 1: program asks user to enter the city name, and
then display that the city has been visited. Please note user can visit a
city any number of times
When user presses 2: Program takes you back to the previous city
When user presses 3: Program terminates
See the below example how program interacts with the user:
C:> 1: Visit a city
program
Enter your choice
2: Go to previous city
3: Quit the
Please enter a city to visit.
Muscat
You are in Muscat now.
Enter your choice.
1: Visit a city
2: Go to previous city
Please enter a city to visit.
Ibra
You are in Ibra noW.
Enter your choice.
1: Visit a city
2: Go to previous city
Please enter a city to visit.
Sohar
You are in Sohar now.
Enter your choice.
1: Visit a city
2
You are in Ibra now.
2: Go to previous city
Enter your choice.
1: Visit a city
2: Go to previous city
Please enter a city to visit.
Nizwa
You are in Nizwa noW.
Enter your choice.
1: Visit a city
2
You are in Ibra now..
2: Go to previous city
Enter your choice.
1: Visit a city
2
2: Go to previous city
You are in Muscat now.
Enter your choice.
1• Visit a city
2
2: Go to previous city
You are back to your original place.
Enter your choice….
1: Visit a city
3
Program terminates.
2: Go to previous city
3: Quit the program
3: Quit the program
3: Ouit the program
3: Quit the program
3: Quit the program
3: Ouit the program
3: Ouit the program
3: Quit the program


Casel: Write a menu driven program that allows you to visit cities of<br>oman in random order with following options.<br>1: Visit a city<br>2: Go to previous city<br>3: Quit the<br>program<br>When user presses 1: program asks user to enter the city name, and<br>then display that the city has been visited. Please note user can visit a<br>city any number of times<br>When user presses 2: Program takes you back to the previous city<br>When user presses 3: Program terminates<br>See the below example how program interacts with the user:<br>C:> 1: Visit a city<br>2: Go to previous city<br>3: Quit the<br>program<br>Enter your choice...<br>1<br>Please enter a city to visit..<br>Muscat<br>You are in Muscat now...<br>Enter your choice...<br>1: Visit a city<br>2: Go to previous city<br>3: Quit the program<br>1<br>Please enter a city to visit..<br>Ibra<br>You are in Ibra now...<br>Enter your choice...<br>1: Visit a city<br>2: Go to previous city<br>3: Quit the program<br>1<br>Please enter a city to visit..<br>Sohar<br>You are in Sohar now...<br>Enter your choice...<br>1: Visit a city<br>2: Go to previous city<br>3: Quit the program<br>2<br>You are in Ibra now...<br>Enter your choice...<br>1: Visit a city<br>2: Go to previous city<br>3: Quit the program<br>1<br>Please enter a city to visit..<br>Nizwa<br>You are in Nizwa now...<br>Enter your choice...<br>1: Visit a city<br>2: Go to previous city<br>3: Quit the program<br>2<br>You are in Ibra now...<br>Enter your choice...<br>1: Visit a city<br>2: Go to previous city<br>3: Quit the program<br>2<br>You are in Muscat now...<br>Enter your choice...<br>1: Visit a city<br>2: Go to previous city<br>3: Quit the program<br>You are back to your original place...<br>Enter your choice...<br>1: Visit a city<br>2: Go to previous city<br>3: Quit the program<br>3<br>Program terminates...<br>

Extracted text: Casel: Write a menu driven program that allows you to visit cities of oman in random order with following options. 1: Visit a city 2: Go to previous city 3: Quit the program When user presses 1: program asks user to enter the city name, and then display that the city has been visited. Please note user can visit a city any number of times When user presses 2: Program takes you back to the previous city When user presses 3: Program terminates See the below example how program interacts with the user: C:> 1: Visit a city 2: Go to previous city 3: Quit the program Enter your choice... 1 Please enter a city to visit.. Muscat You are in Muscat now... Enter your choice... 1: Visit a city 2: Go to previous city 3: Quit the program 1 Please enter a city to visit.. Ibra You are in Ibra now... Enter your choice... 1: Visit a city 2: Go to previous city 3: Quit the program 1 Please enter a city to visit.. Sohar You are in Sohar now... Enter your choice... 1: Visit a city 2: Go to previous city 3: Quit the program 2 You are in Ibra now... Enter your choice... 1: Visit a city 2: Go to previous city 3: Quit the program 1 Please enter a city to visit.. Nizwa You are in Nizwa now... Enter your choice... 1: Visit a city 2: Go to previous city 3: Quit the program 2 You are in Ibra now... Enter your choice... 1: Visit a city 2: Go to previous city 3: Quit the program 2 You are in Muscat now... Enter your choice... 1: Visit a city 2: Go to previous city 3: Quit the program You are back to your original place... Enter your choice... 1: Visit a city 2: Go to previous city 3: Quit the program 3 Program terminates...
Jun 10, 2022
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here