In a Boolean statement, are the true or false values capitalized or not?
Capitalized; True or False
What do comparison values let us do?
Compare two values
What do we start single line comments with?
#
Is 29 a prime number?
yes
What is a boolean?
A boolean is a value that can be either true or false.
What does an if statement do?
Completes indented commands only if a condition is found true
Tracy is facing east (right). What are two ways to get her to face north?
left(90) or right(270)
What is the type of the variable x in the following Python program?
string
What is the largest city (in terms of population) in the USA?
New York
Like integers, Booleans have to be given to the ___ function before they can be concatenated with strings.
str function
What is non-sequential programming?
Programming that may or may not take a detour from the usual order of execution, depending on circumstances.
What is a for loop?
A programming construct that allows us to execute code a predetermined number of times.
FREE 300 POINTS
FREE 300 POINTS
What is the freezing point of water in degrees Fahrenheit?
32 degrees
What do logical operators allow us to do?
Logical operators allow students to connect or modify Boolean expressions. Three logical operators are and, or, and not.
What does an else statement do?
Completes indented commands only if previous conditions are found false
What does each number in this for loop mean?
for i in range(1, 10, 2)
1: starting value for i
10: ending value for i
2: this is the amount to increment i each loop
LOSE A TURN
LOSE A TURN
Who won the Super Bowl last month?
Eagles
After the following code runs, what is the value of is_weekend?
is_saturday = True
is_sunday = False
is_weekend = is_saturday or is_sunday
True
*Remember we work with truth tables!*
What do these comparison operators mean?
==
!=
>
<
>=
<=
Equal to
Not equal to
Greater than
Less than
Greater than or equal to
Less than or equal to
FREE 500 POINTS
FREE 500 POINTS
Will this program run?
x = 4
y = "hi"
print(x + y)
no
LOSE YOUR TURN
LOSE YOUR TURN