Question: Create a class Book with the data members isbn, title, price. Create a class SpecialEdition which is subclass
-
answerhappygod
- Site Admin
- Posts: 899604
- Joined: Mon Aug 02, 2021 8:13 am
Question: Create a class Book with the data members isbn, title, price. Create a class SpecialEdition which is subclass
Question: Create a class Book with the data members isbn, title, price. Create a class SpecialEdition which is subclass of Book and with a data member discountRate. Create a class BookTest with main() to test the above classes Constructors & Methods: Create constructors to give the values to the data members. Values shall come from user. - Create a method display() in Book dass which displays isbn, title and price. Override the same display() of Book class in SpecialEdition. This method displays isbn, btitle, price using super.display() and display the discounted price. No. 1. Marks /5 2. 73 Task Create Book class and its data member Create SpecialEdition class and its data member Book and SpecialEdition constructors Create display() methods 3. 14 4. 14 5. BookTest class 73 6. Correct output 75 TOTAL 720 Submission in Brighten: 1. JAVA files (.java) 2. Program screenshots and paste in docx file.
Join a community of subject matter experts. Register for FREE to view solutions, replies, and use search function. Request answer by replying!