Answered step by step
Verified Expert Solution
Question
1 Approved Answer
PLEASE USE PYTHON Description For this assignment you will write a program to simulate a media library. We will work with three types of media:
PLEASE USE PYTHON
Description For this assignment you will write a program to simulate a media library. We will work with three types of media: pictures, music, and movies. Your job is to design and implement a class hierarchy consisting of the Media, Picture, Song, and Movie classes, as described below Specification for the classes Media class A Media object has a media type, a name, and a rating. The rating is an integer number. You need to implement the init ,getter, and setter methods as needed This class should overload the str displayed using the print ) function or repr methods so that Media objects can be Movie class A Movie is a type of Media that has a director and running time (given in minutes). This class has a play) method that will simulate the task of playing a movie (you can do something simple as printing: '>, playing now'. The Movie class should override the str or reprmethod of Media. Make sure you also implement any other methods (such as_ init_ ,getters, and setters) as needed by Movie. You should be able to use the str _(or_repr_) method in a script to show all the movie information, including media type, name, rating, director, and running time Song class A Song is a kind of Media that has an artist and an album. This class has a play () method that will simulate the task of playing a song (you can do something simple as printing something likeStep 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