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!! :)
B- To ensure that the cities were not overcrowded
Answer:
wait 2minutes I will give you answer
Answer:
D. Senate
Explanation:
The legislative branch keeps the executuve branch in check. The President must receive consent from the Senate before appointing officials.