Write a Python program to implement the following: A . . Design a class called ISBN to
Fantastic news! We've Found the answer you've been seeking!
Question:
Write a Python program to implement the following:
A. Design a class called ISBN to represent an International Standard Book Number or
ISBN for short. The ISBN consists of 10 digits divided into 4 parts.
For example, the ISBN 0941831396 represents the following information:
The first part: The first digit "0" signifies the book is from an English−speaking country.
The second part: "941831" identifies the publisher.
The third part: "39" is the title number for the book.
The fourth part: "6" is a check digit to indicate that the sum of the ISBN digits is 10.
The class should have a constructor and methods to set and get the ISBN as a string.
B. Design a Book class that represents relevant information about a book, including the
book's title, author, publisher, city and date of publication, and price.
The class should also include the field ISBN isbnNum; where ISBN is the class defined
above.
This class should include a constructor and the following methods:
− setBookISBN: to set the ISBN for the book.
− getAuthor: to return the author of the book.
− setAuthor: to set the author of the book.
− getBookISBN: to get the ISBN of the book.
− printDetails: to print the information of a book in the following form:
Book Title: Object First with Python
Book Author: AuthorAA
Publisher: Prentice Hall
ISBN: 0941831396 python
Related Book For
Posted Date: