

Python quiz
Presentation
•
Engineering
•
University
•
Practice Problem
•
Hard
JAGARLAMUDI 23BCE9726
Used 3+ times
FREE Resource
0 Slides • 15 Questions
1
Multiple Choice
What is the correct syntax to print a string in Python?
echo "Hello, World!"
print("Hello, World!")
printf("Hello, World!")
System.out.println("Hello, World!")
2
Multiple Choice
How do you create a list in Python?
{1, 2, 3}
(1, 2, 3)
[1, 2, 3]
list(1, 2, 3)
3
Multiple Choice
Which library is used for data manipulation and analysis in Python?
NumPy
Pandas
Matplotlib
SciPy
4
Multiple Choice
How do you create a tuple in Python?
[1, 2, 3]
{1, 2, 3}
(1, 2, 3)
tuple[1, 2, 3]
5
Multiple Choice
Which of the following is NOT a valid Python data type?
int
float
double
str
6
Multiple Choice
How do you install an external Python library?
install library_name
python -m pip install library_name
include library_name
library_name install
7
Multiple Choice
What is the output of print(type([]))?
<class 'list'>
<type 'list'>
list
[]
8
Multiple Choice
How do you start a for loop in Python?
for (i=0; i<10; i++)
for i in range(10):
for i = 1 to 10:
foreach (i in 10)
9
Multiple Choice
What is the output of print(10 // 3)?
3.33
3
4
None
10
Multiple Choice
What is the correct way to write a conditional statement in Python?
if x > y {}
if x > y:
if x > y then:
if (x > y):
11
Multiple Choice
What will be the output of the following code snippet?
def foo(x=[]):
x.append(1)
return x
print(foo())
print(foo())
[1] [1]
[1] [2]
[1] [1, 1]
[1] [1, 2]
12
Multiple Choice
Which of the following statements about Python's Global Interpreter Lock (GIL) is TRUE?
It allows multi-threading in Python to run concurrently on multiple cores.
It prevents multiple threads from executing Python bytecodes at the same time.
It is specific to Jython and not CPython.
It is used to manage memory allocation across threads.
13
Multiple Choice
What will the following code output?
class A:
def init(self):
self.value = 10
def getattr(self, name):
if name == 'value':
return 20
raise AttributeError
a = A()
print(a.value)
10
20
AttributeError
Depends on Python version
14
Multiple Choice
What is the time complexity of list.pop(0) in Python?
O(1)
O(log n)
O(n)
O(n^2)
15
Multiple Choice
What is the difference between is and == in Python?
is checks value equality, and == checks reference equality.
Both check reference equality.
Both check value equality.
is checks reference equality, and == checks value equality.
What is the correct syntax to print a string in Python?
echo "Hello, World!"
print("Hello, World!")
printf("Hello, World!")
System.out.println("Hello, World!")
Show answer
Auto Play
Slide 1 / 15
MULTIPLE CHOICE
Similar Resources on Wayground
11 questions
Relative Clauses
Presentation
•
12th Grade
10 questions
Cardiovascular System
Presentation
•
University
11 questions
Gestión y Liderazgo Escolar
Presentation
•
University
14 questions
PRESENT SIMPLE
Presentation
•
University
11 questions
AIHM (A)
Presentation
•
University
10 questions
Aula12_6ano_PL
Presentation
•
Professional Development
10 questions
Fase 2 un libro sin rcetas
Presentation
•
Professional Development
10 questions
TRẮC NGHIỆM ÔN TẬP | 51-200
Presentation
•
KG
Popular Resources on Wayground
10 questions
Safety Day 2026 – Student Review
Quiz
•
9th Grade
21 questions
Continents and Oceans
Quiz
•
6th Grade
20 questions
Parts of Speech
Quiz
•
5th Grade
16 questions
Subject & Predicate
Quiz
•
5th Grade
25 questions
Multiplication Facts
Quiz
•
5th Grade
12 questions
Map Skills
Quiz
•
3rd Grade
22 questions
Continents and Oceans
Quiz
•
5th Grade
15 questions
Rounding Decimals
Quiz
•
5th Grade
Discover more resources for Engineering
20 questions
Disney Trivia
Quiz
•
University
10 questions
Spanish Greetings and Goodbyes!
Presentation
•
6th Grade - University
20 questions
Physical or Chemical Change/Phases
Quiz
•
8th Grade - University
39 questions
Unit 7 Key Terms
Quiz
•
11th Grade - University
25 questions
SER and Subject Pronouns
Quiz
•
8th Grade - University
38 questions
Unit 6 Key Terms
Quiz
•
11th Grade - University
19 questions
Key Concepts in Buddhism
Quiz
•
University
0 questions
Cell Domain Basic Review (Biology)
Quiz
•
University