PYTHON "If" Statement

Flashcard
•
Computers
•
6th Grade
•
Hard
Quizizz Content
FREE Resource
Student preview

10 questions
Show all answers
1.
FLASHCARD QUESTION
Front
In Python, what are if-statements used for?
Back
Decision Making
2.
FLASHCARD QUESTION
Front
What is the output of this code?
click = True
Like = 0
if click:
Like = Like + 1
print(Like)
Back
1
3.
FLASHCARD QUESTION
Front
What is the output of the following code?
Temperature = 20
Thermo = 15
if Temperature < 15:
Thermo = Thermo + 5
print(Thermo)
Back
15
4.
FLASHCARD QUESTION
Front
What is the output of the following code?
Time = "Day"
Sleepy = False
Pajamas = "Off"
if Time == "Night" and Sleepy == True:
Pajamas = "On"
print(Pajamas)
Back
off
5.
FLASHCARD QUESTION
Front
What will be the output of the following code?
def max(a, b):
if a > b:
print('a is the max')
else:
print('b is the max')
max(1,2)
Back
b is the max
6.
FLASHCARD QUESTION
Front
What will the be the output of the following code?
if (10<0) and (0 <-10):
print(“A”)
else:
print(“B”)
Options: A, B, AB, BA
Back
B
7.
FLASHCARD QUESTION
Front
Is the following statement true or false?
More than one condition cannot be used with an IF statement.
Back
False
Create a free account and access millions of resources
Similar Resources on Wayground
8 questions
Grok Module 6 Practice

Flashcard
•
7th - 8th Grade
9 questions
HW: Week 2 - Microbits

Flashcard
•
6th - 7th Grade
10 questions
Computer Basics

Flashcard
•
6th Grade
10 questions
Python

Flashcard
•
7th - 8th Grade
10 questions
Python

Flashcard
•
7th - 8th Grade
10 questions
Python

Flashcard
•
7th - 8th Grade
10 questions
Python

Flashcard
•
7th - 8th Grade
10 questions
Python Variables

Flashcard
•
6th Grade
Popular Resources on Wayground
15 questions
Hersheys' Travels Quiz (AM)

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

Quiz
•
6th - 8th Grade
30 questions
Lufkin Road Middle School Student Handbook & Policies Assessment

Quiz
•
7th Grade
20 questions
Multiplication Facts

Quiz
•
3rd Grade
17 questions
MIXED Factoring Review

Quiz
•
KG - University
10 questions
Laws of Exponents

Quiz
•
9th Grade
10 questions
Characterization

Quiz
•
3rd - 7th Grade
10 questions
Multiply Fractions

Quiz
•
6th Grade