
Python Programming Quiz - 2

Quiz
•
Engineering
•
12th Grade
•
Hard
Krishnesh G P
FREE Resource
15 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following is a correct variable declaration in Python?
int x = 5
var x = 5
x = 5
declare x = 5
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What data type is returned by the expression 3 + 2.5 in Python?
Integer
Float
String
Boolean
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which operator is used for exponentiation in Python?
^
**
%
//
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following is a mutable data type in Python?
String
Tuple
List
Integer
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What will be the output of the following code? python Copy code a = 10 b = 20 a, b = b, a print(a, b)
10 10
10 20
20 10
20 20
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following is used to create a conditional statement in Python?
if
for
while
switch
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What will be the output of the following code? python Copy code x = 5 if x > 2: print("A") elif x > 4: print("B") else: print("C")
A
B
C
No output
Create a free account and access millions of resources
Similar Resources on Wayground
16 questions
Computer Networks

Quiz
•
12th Grade
14 questions
Quiz sobre Métodos Cuantitativos

Quiz
•
12th Grade
10 questions
Robótica II - Revisão para a prova

Quiz
•
12th Grade
14 questions
Python 3 - Ciclos y Funciones

Quiz
•
12th Grade
15 questions
PIF-Quiz 3

Quiz
•
9th - 12th Grade
14 questions
NodeMCU Architecture Seatwork

Quiz
•
12th Grade
10 questions
Java Fundamentals Assessment

Quiz
•
12th Grade
14 questions
Bachelor of Science in Electrical Engineering Quiz

Quiz
•
12th Grade
Popular Resources on Wayground
10 questions
Lab Safety Procedures and Guidelines

Interactive video
•
6th - 10th Grade
10 questions
Nouns, nouns, nouns

Quiz
•
3rd Grade
10 questions
9/11 Experience and Reflections

Interactive video
•
10th - 12th Grade
25 questions
Multiplication Facts

Quiz
•
5th Grade
11 questions
All about me

Quiz
•
Professional Development
22 questions
Adding Integers

Quiz
•
6th Grade
15 questions
Subtracting Integers

Quiz
•
7th Grade
9 questions
Tips & Tricks

Lesson
•
6th - 8th Grade
Discover more resources for Engineering
10 questions
9/11 Experience and Reflections

Interactive video
•
10th - 12th Grade
20 questions
Getting to know YOU icebreaker activity!

Quiz
•
6th - 12th Grade
10 questions
Impact of 9/11 and the War on Terror

Interactive video
•
10th - 12th Grade
28 questions
Ser vs estar

Quiz
•
9th - 12th Grade
6 questions
Biography

Quiz
•
4th - 12th Grade
25 questions
ServSafe Foodhandler Part 3 Quiz

Quiz
•
9th - 12th Grade
10 questions
Fact Check Ice Breaker: Two truths and a lie

Quiz
•
5th - 12th Grade
20 questions
Macromolecules

Quiz
•
9th - 12th Grade