OOP | REX03

OOP | REX03

University

10 Qs

quiz-placeholder

Similar activities

Assessment 08

Assessment 08

University

15 Qs

Information Technology & Business Canvas Model

Information Technology & Business Canvas Model

University

13 Qs

CID421 Introduction to 3D CAD SOLIDWORK

CID421 Introduction to 3D CAD SOLIDWORK

University

12 Qs

GIS Unit-1

GIS Unit-1

University

15 Qs

Microcontroller

Microcontroller

11th Grade - University

10 Qs

Input, output and storage de

Input, output and storage de

8th Grade - Professional Development

14 Qs

Computer Architecture Unit 3

Computer Architecture Unit 3

University

15 Qs

BCA

BCA

University

10 Qs

OOP | REX03

OOP | REX03

Assessment

Quiz

Computers

University

Practice Problem

Hard

Created by

Gergő Morvai

Used 1+ times

FREE Resource

AI

Enhance your content in a minute

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

10 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following is NOT a pillar of Object-Oriented Programming (OOP)?

Inheritance

Polymorphism

Encapsulation

Compilation

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the primary purpose of a class in OOP?

To execute code

To store data

To serve as a blueprint for creating objects

To define program flow

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What does the __init_ _ method do in a Python class?

It is a class attribute.

It is a regular method that can be called anytime.

It is a special method that initializes object attributes when an object is created.

It is a method that is called when an object is deleted.

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following best describes inheritance in OOP?

Creating new objects from existing ones

Defining the structure of a class

Allowing a class to inherit attributes and methods from another class

Hiding complex implementation details

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is polymorphism in OOP?

The ability of an object to change its class during runtime

The ability of different classes to use the same method name but perform different actions

The process of bundling data and methods within a class

The ability of a class to have multiple constructors

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following is a benefit of encapsulation?

Code reusability

Data protection

Code readability

Program execution speed

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the purpose of accessors (getters) in encapsulation?

To modify attribute values

To define class attributes

To retrieve attribute values

To control program flow

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?