Question: need python code asap thank you 1. Modify the Movie List 2D program we did in class. a) Enhance the code so it provides the

need python code asap thank you  need python code asap thank you 1. Modify the Movie List
2D program we did in class. a) Enhance the code so it
provides the price column. b) Enhance the program so it has a
provide by year function that lists all the movies that were released

1. Modify the Movie List 2D program we did in class. a) Enhance the code so it provides the price column. b) Enhance the program so it has a provide by year function that lists all the movies that were released in the year the user requests. Have the two enhancements follow the output we already have for phase 2. Rubric for each exercise: Write the exercise number and short blurb in a markdown cell. (5 pts) Put a comment with your name and description at the top of the program. (5 pts) Make sure you meet the requirements of the problem and that it works for all cases. (70 pts) Follow the naming guidelines. (10 pts) Your code should be neat, organized and easy to read. Make sure you are using docstrings to document your program. (10 pts) 1 # Movie - Phase 1 2 # Author: Murach and Yang 3 4 def display_menu(): 5 print("COMMAND MENU") 6 print("list - List all movies") 7 print("add - Add a movie") 8 print("del - Delete a movie") 9 print("exit - exit program") 10 11 def list(movie_list): 12 i = 1 13 print() 14 for movie in movie_list: 15 print(str(i) + "." + movie) 16 i += 1 17 18 print() 19 20 def add(movie_list): 21 movie = input("Movie Name: ") 22 movie_list.append(movie) 23 print(movie + was added to the movie list. ") 24 25 def delete(movie_list): 26 number = int(input("Movie number: ")) 27 if number 1 or number > len(movie_list): 28 print("Invalid movie number. In") 29 else: 30 movie movie_list.pop(number-1) 11 BE 28 print( Invalid movie number. In") 29 else: movie movie_list.pop(number-1) B1 print(movie was deleted. ") 32 33 def main(): 34 movie list ["A Star is Born", 35 "An Old Man and a Gun", 36 "X-Men"] B7 38 display_menu() B9 command input("Enter Command: ") 40 41 while (command.lower() { "exit"): 42 43 if command lower() = "list": 144 list(movie_list) 45 display_menu() 46 elif command.lower() e "add" 12 add(movie_list) 28 display_menu() 49 elif command.lower() == "del": 50 delete(movie_list) display_menu() else: 58 print("Not a valid command. Please try again. ") command input("Enter Commandem 36 52 print (you 21 be back!") display menu elif command.lower() "de IME delete(movie list) display_menu() else: print("Not a valid command. Please try again. ") 48 49 50 51 52 53 54 55 56 57 58 59 if 60 61 command input("Enter Command: ") print("You'll be back!") TI main": name main()

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!