1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
lora16 [44]
3 years ago
7

Give an example of an IS-A (inheritance) relationship and a separate example of a HAS-A (composition) relationship within the fi

elds of either mathematics, biology, or engineering. The example should be different from one given in class. Explain why these are appropriate examples.
Social Studies
1 answer:
lord [1]3 years ago
4 0

Inheritance (is-a) relationships are derived child classes that inherit attributes and methods from their parent class. Composition (has-a) relationships are classes whose attributes are comprised of other classes. Each relationship has its advantages and disadvantages. See the link below for best uses of each.

For example:

class Animal { }

class Dog extends Animal { }

This means Dog IS-A animal

2. HAS-A simply means reference

For example:

class Nip { }

class Dog { private Nip nip;}

This means Dog HAS-A Nip

Hope this helped!! :)

You might be interested in
In which part of Africa do you think groups had the best opportunities to trade by sea
Aneli [31]
<span>Kingston Africa is probably the best place to have trading by sea. Nearly all coastal towns are ideal. !</span>
7 0
3 years ago
What was the name of the child born on the Mayflower
Nina [5.8K]

Answer:

his name was oceanus hopkins

Explanation:

3 0
3 years ago
Read 2 more answers
Based on the map above, which world regions are the most densely populated?
Kay [80]

Answer:

theres no map

but there is extra points ! for mee

Explanation:

3 0
3 years ago
Read 2 more answers
The area of a pumpkin pie is 225 Pi square centimeters. What is the circumference of the pumpkin pie
Volgvan

Answer: 450.28

Explanation:

225 divided by 3.14=71.7 so R=71.7 and the diameter would be 143.4 and C=3.14x143.4= 450.28

4 0
2 years ago
Please confirm that this awnser is right please only awnser if you are 100% sure it’s right ( I will brainlist)
MArishka [77]

Answer:

it is right

Explanation:

Animals get the nitrogen they need by eating plants or other animals that contain nitrogen. When organisms die, their bodies decompose bringing the nitrogen into soil on land or into ocean water. Bacteria alter the nitrogen into a form that plants are able to use.

7 0
3 years ago
Read 2 more answers
Other questions:
  • Which part of the diagram represents the protons
    10·1 answer
  • The measure of arc QS is (4x-18)° what is the value of x?
    15·2 answers
  • Napoleon owns napoleon's construction and agrees to renovate mrs. cernan's bathroom. she will provide him with the plans, and th
    8·1 answer
  • Is Madison the capital of Michigan Minnesota or wisconsin
    6·2 answers
  • Jessica works at a fast-food restaurant where hamburgers are cooked on a conveyer belt so that no ingredients (nor employee’s mo
    6·1 answer
  • How did the Alps have an impact on Rome?
    14·1 answer
  • PLZ HELP WITH THESE I NEED NOW!
    11·1 answer
  • Of all the things Bacon says to visit, he lists some that need not be visited. These are _____ .
    5·1 answer
  • Alan and Tonny are neighbors and have a long history of disputes. Alan alleges that Tonny slapped him in their last argument. Al
    13·1 answer
  • What is the name of the biochemical pathway describing the conversion of lactate to glucose?
    5·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!