Python OOP and Data Types Quiz

Python OOP and Data Types Quiz

University

30 Qs

quiz-placeholder

Similar activities

E R Diagram

E R Diagram

University

25 Qs

Midterm Exam - Comp Vision - Part 1

Midterm Exam - Comp Vision - Part 1

University

25 Qs

Relational Database Model

Relational Database Model

University

25 Qs

Python Programming

Python Programming

University

25 Qs

CSC408_Chapter 5: Foundation of Business Intelligence

CSC408_Chapter 5: Foundation of Business Intelligence

University

30 Qs

Lenguajes programación

Lenguajes programación

10th Grade - University

25 Qs

Quiz - HTML Overview

Quiz - HTML Overview

University

25 Qs

Bài test Python cơ bản

Bài test Python cơ bản

University

30 Qs

Python OOP and Data Types Quiz

Python OOP and Data Types Quiz

Assessment

Quiz

Computers

University

Easy

Created by

inocencio madriaga

Used 13+ times

FREE Resource

30 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following best defines Object-Oriented Programming (OOP)?

A programming paradigm focused only on functions

A programming paradigm based on objects that contain data and behavior

A language-specific coding style

A way to run Python faster

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

In Python, which symbol is used to indicate a private attribute?

_ (single underscore)

__ (double underscore)

@

$

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which OOP principle is applied when a child class inherits methods and attributes from a parent class?

Abstraction

Polymorphism

Encapsulation

Inheritance

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which Python data type is immutable?

List

Dictionary

Tuple

Set

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What will be the output of: print(10 % 3)

0

1

2

3

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following is an example of abstraction in Python?

Using private attributes

Hiding implementation details with abstract classes

Sharing methods across multiple classes

Reusing code with inheritance

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which loop is best suited for iterating over a sequence?

while

do-while

for

switch

Create a free account and access millions of resources

Create resources
Host any resource
Get auto-graded reports
or continue with
Microsoft
Apple
Others
By signing up, you agree to our Terms of Service & Privacy Policy
Already have an account?