Skip to main content

Practice · 3 of 5

Constructor chaining

CHALLENGE
Difficulty: intermediate+25 XP

Complete makeCar(): build a Car "taxi" with 4 doors and return "taxi:4". The Car constructor must chain super(label) first — the lesson's rule 1.

Back to lesson: Practice: Inheritance lab