[JAVA] Design an inheritance in JAVA.

Microsoft Visual C#
7th Edition
ISBN:9781337102100
Author:Joyce, Farrell.
Publisher:Joyce, Farrell.
Chapter10: Introduction To Inheritance
Section: Chapter Questions
Problem 20RQ
icon
Related questions
Question

[JAVA] Design an inheritance in JAVA.

Find a parent class (abstract) and 2 child classes (abstract/concrete - up to you) and at least 1 grandchild (concrete).
There should also be an interface which you can use in any of the classes, does not matter which one.
• Each class should have at least 2 inner properties (instance variables) + at least 1 method and the interface should have at least 1
method.
You can design the inheritance of any of the following:
o Furnitures
o Trees
о Тoys
Liquids
o Plants
o Household
You can use draw.io to draw your class diagrams OR you can draw them on paper, take a picture, and upload the picture of
your drawing. Name your answer as "Q2"
Transcribed Image Text:Find a parent class (abstract) and 2 child classes (abstract/concrete - up to you) and at least 1 grandchild (concrete). There should also be an interface which you can use in any of the classes, does not matter which one. • Each class should have at least 2 inner properties (instance variables) + at least 1 method and the interface should have at least 1 method. You can design the inheritance of any of the following: o Furnitures o Trees о Тoys Liquids o Plants o Household You can use draw.io to draw your class diagrams OR you can draw them on paper, take a picture, and upload the picture of your drawing. Name your answer as "Q2"
Expert Solution
steps

Step by step

Solved in 3 steps with 6 images

Blurred answer
Knowledge Booster
Class
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
Microsoft Visual C#
Microsoft Visual C#
Computer Science
ISBN:
9781337102100
Author:
Joyce, Farrell.
Publisher:
Cengage Learning,
C++ Programming: From Problem Analysis to Program…
C++ Programming: From Problem Analysis to Program…
Computer Science
ISBN:
9781337102087
Author:
D. S. Malik
Publisher:
Cengage Learning
EBK JAVA PROGRAMMING
EBK JAVA PROGRAMMING
Computer Science
ISBN:
9781337671385
Author:
FARRELL
Publisher:
CENGAGE LEARNING - CONSIGNMENT
Programming Logic & Design Comprehensive
Programming Logic & Design Comprehensive
Computer Science
ISBN:
9781337669405
Author:
FARRELL
Publisher:
Cengage