Search Header Logo

Day 76 - CS Quizizz

Authored by Courtney Yatteau

Computers

11th Grade

Used 1+ times

Day 76 - CS Quizizz
AI

AI Actions

Add similar questions

Adjust reading levels

Convert to real-world scenario

Translate activity

More...

    Content View

    Student View

5 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Does a Subclass need to have a constructor?

No, it can inherit the constructor from the Superclass.

Yes, it must always have an explicit constructor to take the parameteres of the superclass.

No, subclasses objects are part of the superclass object, so the superclass constructor is called.

Yes, the subclass has its own constructor, either explicit or implicitly created.

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

How does a Subclass call the Superclass constructor?

Using the super keyword in a separate method within the subclass

Using the Superclass name in a separate method within the subclass

Using the super keyword in the first line of the subclass constructor.

Using the Superclass name in the first line of the subclass constructor.

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

If a superclass constructor exists and a subclass doesn’t explicitly call the that constructor, what happens?

Java implicitly calls the no-argument superclass constructor

Java doesn’t create a superclass object

The program will not compile and will generate an error.

Java initializes all superclass variables with default values.

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

If a class does not extend any class, what happens?

Nothing. Not every class needs to have a superclass.

The program will not compile and will throw an error.

The class with the main method becomes the superclass.

By default, we extend the Object class

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

True or False: A subclass can be extended by another class to become a superclass.

True

False

Access all questions and much more by creating a free account

Create resources

Host any resource

Get auto-graded reports

Google

Continue with Google

Email

Continue with Email

Classlink

Continue with Classlink

Clever

Continue with Clever

or continue with

Microsoft

Microsoft

Apple

Apple

Others

Others

Already have an account?