"Starting out with Python, ['Tony Gaddis'], 4th, 739.00 NOK, ['Introduction to Programming', 'Introduction to Python', 'Control Statements', 'Functions', 'Introduction to Programming', 'Introduction to Python', 'Control Statements', 'Functions']\n",
"Starting out with Python, [], 4th, 126.65 USD, []\n",
"Starting out with Python, ['Tony Gaddis'], 4th, 739.00 NOK, ['Introduction to Programming', 'Introduction to Python', 'Control Statements', 'Functions', 'Introduction to Programming', 'Introduction to Python', 'Control Statements', 'Functions']\n",
"Title = Starting out with Python, Auhor = ['Tony Gaddis'], Edition = 4th, Price = 739, Currency = NOK\n",
"Starting out with Python, ['Tony Gaddis'], 5th, 985.60 NOK, ['Introduction to Programming', 'Introduction to Python', 'Control Statements', 'Functions', 'Introduction to Programming', 'Introduction to Python', 'Control Statements', 'Functions']\n"
]
}
],
"source": [
"from Book import Book\n",
"\n",
"\n",
"sowp_akademika = Book(title=\"Starting out with Python\", edition='4th')\n",
"sowp_akademika.set_price(739)\n",
"sowp_akademika.set_currency('NOK')\n",
"sowp_akademika.add_author('Tony Gaddis')\n",
"sowp_akademika.set_pages(896)\n",
"sowp_akademika.add_chapter('Introduction to Programming')\n",
"sowp_akademika.add_chapter('Introduction to Python')\n",
sowp_akademika=Book(title="Starting out with Python",edition='4th')
sowp_akademika.set_price(739)
sowp_akademika.set_currency('NOK')
sowp_akademika.add_author('Tony Gaddis')
sowp_akademika.set_pages(896)
sowp_akademika.add_chapter('Introduction to Programming')
sowp_akademika.add_chapter('Introduction to Python')
sowp_akademika.add_chapter('Control Statements')
sowp_akademika.add_chapter('Functions')
sowp_amazon=Book(title="Starting out with Python",edition='4th')
sowp_amazon.set_price(126.65)
sowp_amazon.set_currency('USD')
sowp_akademika.add_chapter('Introduction to Programming')
sowp_akademika.add_chapter('Introduction to Python')
sowp_akademika.add_chapter('Control Statements')
sowp_akademika.add_chapter('Functions')
print(sowp_akademika)
print(sowp_amazon)
print(str(sowp_akademika))
print(repr(sowp_akademika))
sowp_akademika(price=896*1.1,edition='5th')
print(sowp_akademika)
```
%% Output
Starting out with Python, ['Tony Gaddis'], 4th, 739.00 NOK, ['Introduction to Programming', 'Introduction to Python', 'Control Statements', 'Functions', 'Introduction to Programming', 'Introduction to Python', 'Control Statements', 'Functions']
Starting out with Python, [], 4th, 126.65 USD, []
Starting out with Python, ['Tony Gaddis'], 4th, 739.00 NOK, ['Introduction to Programming', 'Introduction to Python', 'Control Statements', 'Functions', 'Introduction to Programming', 'Introduction to Python', 'Control Statements', 'Functions']
Title = Starting out with Python, Auhor = ['Tony Gaddis'], Edition = 4th, Price = 739, Currency = NOK
Starting out with Python, ['Tony Gaddis'], 5th, 985.60 NOK, ['Introduction to Programming', 'Introduction to Python', 'Control Statements', 'Functions', 'Introduction to Programming', 'Introduction to Python', 'Control Statements', 'Functions']