Question: (a) In a file called music.py, create a Song class that contains the following: The private data fields name, minutes, seconds for the name of

 (a) In a file called music.py, create a Song class that

(a) In a file called music.py, create a Song class that contains the following: The private data fields name, minutes, seconds for the name of a song 1. and its length in minutes and seconds A constructor with arguments for name, time (both strings). The time string shoud be in the format mm:ss Accessor methods for name, minutes, and seconds (b) Add to your music.py file to create an Album class that contains the fol lowing . The private data fields title, artist, and date (all strings) for the title of the album, the name of the artist, and the release date (year) as wel as a list of Songs (in data field songs) A constructor with arguments for title, artist, and date Accessor methods for title, artist, date, and songs A method to add a Song to the Album. A method to calculate the total length (time) of the Album in the format hh:mm:ss (c) Write a main function, in music.py, to illustrate the use of your Album and Song classes Sample input/output Enter name of album: Album1 Enter the name of the artist: Artist1 Enter the release date: 2018 How many songs? 3 Enter name of song: Song1 Enter the length of the song (mm:ss): 03:43 Enter name of song: So Enter the length of the song (mm:ss): 04:02 Enter name of song: Song3 Enter the length of the song (mm:ss): 02:58 Album length (hh:mm:ss) is 00:10:43 ngz

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!