Writing Constructors for Subclasses

AP Computer Science A· difficulty 4/5

When constructing a subclass object, the parent's constructor

  • A

    Is skipped

  • B

    Runs last

  • C

    Runs first (implicitly via super() if not called explicitly)

    check_circle
  • D

    Throws exception

Explanation

Java auto-inserts super() (no-arg) if you don't call super(args) explicitly.

Want 10 more like this — adaptive to your weak spots?

Related questions