subject

Create a class named Employee with a name and a salary. Make a class named Manager that inherits from Employee with an instance field named department. Supply a toString() method that prints the manager's name, department, and salary. Make another class named Director that inherits from Manager with an instance field named stipendAmount. Supply the toString() method for Director that prints all of its instance variables. Also, write a program named myOutput that instantiates an object of each of the classes and invokes the toString() method of each of the objects.

ansver
Answers: 1

Another question on Computers and Technology

question
Computers and Technology, 23.06.2019 02:30
Which component acts as a platform on which application software runs
Answers: 2
question
Computers and Technology, 23.06.2019 05:20
What did creator markus “notch" persson initially call his game
Answers: 1
question
Computers and Technology, 23.06.2019 12:00
Which of these is an example of an integrated presentation? a. a table created in powerpoint b. an image pasted into powerpoint c. a caption created in powerpoint d. an excel chart pasted into powerpoint
Answers: 1
question
Computers and Technology, 24.06.2019 02:50
Be sure to answer all parts. synthesize the following compound from benzene. a. b. c. d. e. f. reaction [1] conditions: a b c d e f reaction [1] product: draw structure reaction [2] conditions: a b c d e f reaction [2] product: draw structure reaction [3] conditions: a b c d e f reaction [3] product:
Answers: 3
You know the right answer?
Create a class named Employee with a name and a salary. Make a class named Manager that inherits fro...
Questions