This data type represents sequences of characters.
What is string?
This built-in function is automatically called to update the screen each frame (60 times per second).
What is draw()?
The comparison operator to check for equality.
What is ==?
Command that would allow you to take in a price from the user (like 1.50 for a donut)
(answers may vary)
What is price = float(input("What is the price of a donut?")
The name of the input a function will receive.
Ex: numSides is the ______ in
polygon(numSides)
What is parameter?
This data type is used for whole numbers and their opposites.
What is integer?
This function is triggered automatically when the mouse is clicked.
What is on_mouse_down(pos)?
The comparison operator to check for inequality (not equal).
What is !=?
If "score" tracks the number of correct answers out of 40 questions, this expression would calculate the percentage correct.
score/40 * 100
The specific value of a parameter.
Ex: The value 5 is the ____for numSides
polygon(numSides) --> polygon(5)
What is argument?
This data type is used for fractional (decimal) values.
What is float?
This line must be included at the end of every Pygame Zero file to run it properly.
What is pgzrun.go()?
"Else if" in Python.
What is elif?
Assuming "import math", this expression in python:
sqrt(b^2 - 4 ac
What is math.sqrt(b**2 - 4 *a*c)?
The operation that gives the remainder of a division problem.
What is modulus?
This data type has only two values, True or False.
What is Boolean?
This command sets an image named "poodle.png" as a sprite like character stored in the variable dog
dog = Actor("poodle")
The syntax error in this code:
if score > 64
print("You passed")
else
print("You failed")
What is a missing colon?
:
It’s midnight. This expression gives the military time 175 hours later.
175%24
What is integrated development environment?
This Python data type is used to handle imaginary numbers, in the form "a + bj"
Note: Python uses j instead of i to represent the imaginary unit.
What is complex?
Assuming an 800×600 screen, this conditional moves a dog actor back to the left side once it crosses the right edge.
if dog.x > 800:
dog.x = 0
Condition to check if a string stored in a variable "guess" is NOT an empty string.
What is
if guess != "":
Complete the missing expression to print if a variable called "number" holds an even number.
if ______________:
print(number + " is even.")
else:
print(number + " is odd.")
What is
number%2 == 0
?
The fancy word for joining strings with calculations or values held in variables
What is concatenation?