Practice · 3 of 5
Constructor delegation
CHALLENGE
Difficulty: beginner+25 XP
Implement the Point nested class: the two-arg constructor stores x and y; the no-arg constructor must call this(0, 0) (delegation, not duplication); both getters return the fields.
Press Submit to check your solution.
Back to lesson: Practice: Design reps