
питон 2

Quiz
•
English
•
Professional Development
•
Easy
кек .
Used 1+ times
FREE Resource
29 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following is the correct syntax for an if statement in Python?
if x > 5:
if (x > 5)
if x > 5 then:
if x > 5 {}
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which operator is used for comparison in Python?
==
=
><
===
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the correct way to write an else statement in Python?
else:
else if:
elseif:
else do:
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which method in Python is used to convert a string to uppercase?
upper()
toUpperCase()
capitalize()
uppercase()
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which statement is used to handle exceptions in Python?
try-except
catch
error
throw
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following is the correct syntax for defining a class in Python?
class MyClass:
MyClass class:
define MyClass:
class MyClass():
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What does the continue statement do in a loop in Python?
Skips the rest of the current loop iteration.
Exits the loop completely.
Restarts the loop from the beginning.
Breaks the loop and goes to the next statement.
Create a free account and access millions of resources
Similar Resources on Wayground
25 questions
Comparative vs. Superlatives

Quiz
•
Professional Development
24 questions
E2F Units 1-2

Quiz
•
Professional Development
25 questions
UTS Bahasa Inggris Kelas 7 GASAL

Quiz
•
Professional Development
25 questions
Elementary EF unit 1

Quiz
•
Professional Development
25 questions
私は誰?Part-1

Quiz
•
Professional Development
24 questions
A2 low Quiz (Units 5-6)

Quiz
•
Professional Development
25 questions
March- English Language QUIZ

Quiz
•
Professional Development
25 questions
A1 Final Exam

Quiz
•
Professional Development
Popular Resources on Wayground
11 questions
Hallway & Bathroom Expectations

Quiz
•
6th - 8th Grade
20 questions
PBIS-HGMS

Quiz
•
6th - 8th Grade
10 questions
"LAST STOP ON MARKET STREET" Vocabulary Quiz

Quiz
•
3rd Grade
19 questions
Fractions to Decimals and Decimals to Fractions

Quiz
•
6th Grade
16 questions
Logic and Venn Diagrams

Quiz
•
12th Grade
15 questions
Compare and Order Decimals

Quiz
•
4th - 5th Grade
20 questions
Simplifying Fractions

Quiz
•
6th Grade
20 questions
Multiplication facts 1-12

Quiz
•
2nd - 3rd Grade