Multiple choice java core java

A "has a" relationship between classes represents ___ and "is a" represents__

  1. 1.static,nonstatic class

  2. 2.Inheritance,Composition

  3. 3.Composition,Inheritance

  4. 4.Overriding,Overloading

Reveal answer Fill a bubble to check yourself
C Correct answer
Explanation

A 'has a' relationship represents Composition (one object contains another), while 'is a' represents Inheritance (one object is a type of another). Option C correctly identifies this mapping. Option B reverses them, and options A/D describe unrelated concepts.