Question
need help with this in C++ Problem: You are asked to create a program for storing the catalog of movies at a DVD store. The
need help with this in C++
Problem:
You are asked to create a program for storing the catalog of movies at a DVD store. The program should let the user add, remove, and output movies.
1) Menu
The menu should be looped and take input from STDIN (Standard input). Depending on the input, the program will have different actions.
The menu should look like this (start the menu with a newline to separate every iteration of the loop):
Menu: A - Add Movie R - Remove Movie O - Output Movie Info C - Output Catalog Info Q - Quit Program Choose an option:
2) (A) Add Movie
When option "A" is chosen from the menu, the Add Movie dialog should appear, asking for inputs:
- Movie Name:
- Year:
- Genre:
Followed with a confirmation message letting the user know the movie was added to the catalog.
Choose an option: A Movie Name: Terminator Year: 1984 Genre: Action Added Terminator to the catalog
3) (R) Remove Movie
When option "R" is chosen from the menu, the Remove Movie dialog should appear asking for inputs:
- Movie Name:
You must then search the catalog for the movie.
If found, remove the movie from the catalog and print a confirmation message:
Choose an option: R Movie Name: Terminator Removed Terminator from catalog
If not found, print an error message letting the user know the movie was not found:
Choose an option: R Movie Name: Inception Cannot find Inception
4) (O) Output Movie Info
When option "O" is chosen from the menu, the Output Movie Info dialog should appear asking for inputs:
- Movie Name:
You must then search the catalog for the movie.
If found, print the movie's info:
Movie Name: Terminator Name: Terminator Year: 1984 Genre: Action
If not found, print an error message letting the user know the movie was not found:
Movie Name: Terminator Cannot find Terminator
5) (C) Output Catalog Info
When option "C" is chosen from the menu, the Output Catalog Info dialog should appear.
There are no inputs in this dialog.
Print the number of movies in the catalog followed by each movie's info:
There are 2 movies in the catalog Name: Terminator Year: 1984 Genre: Action Name: Inception Year: 2010 Genre: Action
6) (Q) Quit Program
When option "Q" is chosen from the menu, you must stop the loop for the menu and print the message "Quitting Program":
Choose an option: Q Quitting Program
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started