Question
Simple C++ Movie Program Create a collection of movies program with C++ by leveraging structs and vectors. The program should allow the user to enter
Simple C++ Movie Program
Create a collection of movies program with C++ by leveraging structs and vectors.
The program should allow the user to enter new movie data and view existing movie data.
Each movie should be a struct that contains the title, release year, length in minutes, and a vector of actors in the movie.
Each actor should be a struct that contains the actor's name and date of birth (stored as an int array of month, date, and year).
All of the movie structs should be saved in a vector. ? You should end up with functions to add a movie and view a movie.
SAMPLE CONSOLE OUTPUT:
Select an option: ? 0 - exit ? 1 - add a movie ?
1 ?
Movie title: Saving Mr. Banks ?
Release year: 2013
Length (min): 125 ?
Actor's name: Emma Thompson
Date of birth
month: 4 ?
date: 15 ?
year: 1959 ?
Add another actor? (y): Y
Actor's name: Tom Hanks
Date of birth
month: 7 ?
date: 9 ?
year: 1956
Add another actor? (y): n
Select an option: ? 0 - exit ? 1 - view Saving Mr. Banks (2013) ? 2 - add a movie
2
Movie title: Gravity
Release year: 2013
Length (min): 91 ?
Actor's name: Sandra Bullock
Date of birth
month: 7
date: 26
year: 1964
Add another actor? (y): y
Actor's name: George Clooney
Date of birth
month: 5
date: 6
year: 1961
Add another actor? (y): n ?
Select an option: ? 0 - exit ? 1 - view Saving Mr. Banks (2013) ? 2 - view Gravity (2013) ? 3 - add a movie
1
Saving Mr. Banks (2013) ? length: 125 min. ? actors: ? Emma Thompson (d.o.b. 4/15/1959) ? Tom Hanks (d.o.b. 7/9/1956)
?Select an option: ? 0 - exit
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