subject

You are going to be working with 4 classes, a Book superclass with TextBook and Novel subclasses, and a BookTester class to run your program. For the Book, TextBook, and Novel class, you will create a constructor and all getters and setters. Be sure to follow standard naming conventions for your getters and setters! Additional information for each class is below. Book Class
The Book class will have a title and author as instance variables and the constructor should follow this format:
public Book(String title, String author)
TextBook Class
The TextBook class will have a subject and edition as instance variables and the constructor should follow this format:
public TextBook(String title, String author,
String subject, String edition)
Novel Class
The Novel class will have a genre and pages as instance variables and the constructor should follow this format:
public Novel(String title, String author,
String genre, int pages)
BookTester
In the tester class, you should create an ArrayList that will store all the books in your library. Then create you library by adding at least 3 textbooks and 3 novels to the ArrayList.
After creating your library, use a loop to access the ArrayList and print out any information you have access to.
public class Novel extends Book
{
// Start here!
}
public class Book
{
// Start here!
}
public class TextBook extends Book
{
// Start here!
}
import java. util. ArrayList;
public class BookTester
{
public static void main(String[] args)
{
// Start here!
}
}

ansver
Answers: 2

Another question on Computers and Technology

question
Computers and Technology, 24.06.2019 08:00
Java the manager of a football stadium wants you to write a program that calculates the total ticket sales after each game
Answers: 1
question
Computers and Technology, 24.06.2019 10:00
1. which of these is not true about torsion bars? a. they can be used to adjust ride height b. they can be adjusted anytime since they don't affect alignment angles c. they attach between the frame and the lower control arm d. they twist to produce a spring effect
Answers: 1
question
Computers and Technology, 24.06.2019 12:50
What percentage of teens plays video games? a.97% b.100% c.74% d.50%
Answers: 1
question
Computers and Technology, 24.06.2019 22:30
When can you access the bios setup utility?
Answers: 1
You know the right answer?
You are going to be working with 4 classes, a Book superclass with TextBook and Novel subclasses, an...
Questions
question
Mathematics, 14.07.2019 15:30