Starting from:

$20

A movie collection program

In this lab, you will create a movie collection program. You will only be collecting information about a single movie in this lab.

Solution
Your program should display a menu with a list of options for the user.

1. List Movies

2. Add Movie

3. Remove Movie

4. Quit

Keep displaying the menu until the user elects to quit the program. Note, you may use numeric or letter keys to provide your menu. If you use letters, make it case insensitive.

Movie Information
A movie will consist of the following information

Name
Type
Required
Comments
Title
Text
Y
Unique title of the movie.
Description
Text
N
Optional description of the movie.
Length
Integer
N
Length of the movie in minutes (default to 0). If specified then it must be = 0.
Owned
Boolean
Y
True if the movie is owned or false if it is on the wishlist.

Add
Prompt the user for each piece of information about the movie. This lab accepts a single movie. If the user selects to add another movie, overwrite the original movie.

For each value check that the value is correct based upon the rules given earlier and keep prompting the user until the data is valid (i.e. until the length is = 0).

Note: Validating the title is unique is not necessary for this lab since there is only one movie.

List
Display the movie information. Each value should be displayed on its own line with a label indicating what it represents.

If there are no movies then display “No movies available”.

Remove
Prompt the user to confirm they want to delete the movie. If they confirm the deletion then clear the movie information.

Quit
Exit the program.

Requirements
Your program must meet all the following requirements.

· Compile cleanly with no warnings or errors.

· Meet all the points mentioned in the solution.

· Ensure each file has a file header indicating the course, your name and date.

· Solution, project and code should be uploaded to Github

· Submit lab in MyTCC by providing link to Github URL

More products