Inheritance + java

Inheritance + java

University

9 Qs

quiz-placeholder

Similar activities

Quiz #2 ETEC 486 | Spr. 16

Quiz #2 ETEC 486 | Spr. 16

KG - University

10 Qs

Programming

Programming

University

10 Qs

SEDUCA

SEDUCA

University

10 Qs

Java Control Flow statements

Java Control Flow statements

University

10 Qs

Applet Java

Applet Java

University

10 Qs

Quiz 6 PBO

Quiz 6 PBO

University

10 Qs

U26 Q7 - CIDR

U26 Q7 - CIDR

KG - University

12 Qs

OOPJ #1

OOPJ #1

University

10 Qs

Inheritance + java

Inheritance + java

Assessment

Quiz

Computers

University

Practice Problem

Medium

Created by

Vivek Kumar

Used 15+ times

FREE Resource

AI

Enhance your content in a minute

Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...

9 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Inheritance is used when the relationship between two classes: _______ relationship.

"HAS-A"
"PART-OF-A"
"IS-A"
inverse

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

A class that is inherited is called a ______ .

superclass

Subclass

subsetclass

Relativeclass

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What does polymorphism mean?

Changing shapes
Having many forms
Being unchangeable
Easy

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which Java statement represents inheritance?

class body inherit Car

class body super Car

class body extends Car

class body override Car

5.

MULTIPLE SELECT QUESTION

45 sec • 1 pt

Which of the following is/are true about inheritance in Java?

I. A subclass inherits all the methods and variables of the superclass.

II. A subclass can override the methods of its superclass

III. A subclass has access to the private instance variables of the superclass.

I only

II only

III only

I and II only

I and III only

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

super keyword is used to access

only subclass methods

parent class variables and methods

subclass variables and methods

only parent class methods

7.

MULTIPLE CHOICE QUESTION

20 sec • 1 pt

A class member declared protected becomes a _______member of subclass.

public

private

protected

default

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?

Discover more resources for Computers