Created
December 11, 2013 19:19
-
-
Save px-amaac/7916626 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from Materials import Materials | |
class Book(Materials): | |
def __init__(self, d): | |
super().__init__(d[0], d[1], d[2], d[9]) | |
d.pop(9) | |
for i in range(3): | |
d.pop(0) | |
self.data = d | |
def __str__(self): | |
return "Author: " + self.data[0] + '\n' | |
+ "Description: " + self.data[1] + '\n' | |
+ "Publisher: " + self.data[2] + '\n' | |
+ "City: " + self.data[3] + '\n' | |
+ "Year: " + self.data[4] + '\n' | |
+ "Series: " + self.data[5] + '\n' | |
+ "Type: Book\n" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment