Your instructor may assign one or more of the following problems.

  1. Design and build a class hierarchy for media types. Your hierarchy should support Books, Periodicals, DVDs and CDs. Some attributes for these kinds of objects include: title, author, ISBN number, subject, running time, volume number, rating, and lending length. Store each of these attributes in the appropriate place in the hierarchy and override the __str__() method of each class in an appropriate manner.

    Write a program that creates a list of media types and uses that to demonstrate the correctness of your design and implementation. One way to do this would be to write a separate driver module that imports your media classes and then does the following:

    Because there is so little functionality required for these classes, you don’t need to implement formal unit tests for this assignment.

Checking In

Submit all appropriate files for grading, including code files, screen captures, supplemental files (e.g., image files), and text files. We will grade this exercise according to the following criteria: