Are you taking CLEP classes? Try clep.ai
| preferred AP College board partner for AP classes
AP Computer Science A/Unit 9: Inheritance
Start Practice TestPractice Test
About Exam
easy

Inheritance and Is-A Relationships

Mark
< Prev
Next >

Which of the following code segments demonstrates an ‘is-a’ relationship established through inheritance?

A
public class Cat { }
public class Dog { }
B
public class Engine { }
public class Car {
    Engine engine = new Engine();
}
C
public class House {
    // House contains a door, not a type of door
    Door door;
}
D
public class Quadrilateral { }
public class Rectangle extends Quadrilateral { }
Hint
Did You Know?
Explain Why
Explain All Answers
Check Answer
Show Correct Answer
Report Question

Question Leaderboard

Not enough data yet to show leaderboard.

AI Tutor

How can I help?

APFIVE © 2020.
Email: apfive@apfive.org|Privacy Policy|