No student devices needed. Know more
30 questions
Shape sprites require multiple arguments, each of which must be in a specific order and of the correct data type.
True
False
Which of the following is a string?
50
o
"50"
50.0
Select the integer:
50
5o
58.0
"50"
Select the float:
50
50.0
"50"
5o
The syntax for assigning actions to specific sprites is called
dot variables
dot notation
variable notation
variable assignment
What will happen when we run this program?
tom will move up 100 pixels
jerry will move up 100 pixels
syntax error: sprite is not defined
sprite will move up 100 pixels
How should we make the astronaut move up?
change jerry to sprite
change sprite.move_up() to jerry.move_up()
change sprite.move_up() to tom.move_up()
change sprite.move_up() to astronaut1.move_up()
Changing the value of a variable will change its value wherever the variable is used.
True
False
What is the value of interest?
6
9
27
33
What is the value of area?
250
10
This will cause a logic error
This will cause a syntax error
User input is always a string
True
False
What command would be used to cast (convert) user input to an integer?
str()
float()
integer()
int()
How do you create a comment in Python?
Place ** at the beginning of the line
Place \\ at the beginning of the line
Place # at the beginning of the line
Place "" at the beginning of the line
What would happen when you run this code?
Syntax error: the range must be greater than 0
Logic Error: the loop runs 0 times
What is the value of x and the value of the sprite's x-coordinate when the loop finishes running?
x = 0, the sprite's x-coordinate = 0
x = 0, the sprite's x-coordinate = 100
x = 100, the sprite's x-coordinate = 100
x = 100, the sprite's x-coordinate = 0
What is the value of x and the value of the sprite's x-coordinate when the loop finishes running?
x = 0, the sprite's x-coordinate = 0
x = 100, the sprite's x-coordinate = 90
x = 100, the sprite's x-coordinate = 100
x = 100, the sprite's x-coordinate = 110
The user enters 25. What happens next?
The sprite says "That's right!"
The sprite says "Hmm....try again!"
Which line of code would correct the logic error, so that when the user enters 25 the sprite says "That's right!"
answer = sprite.ask.int("What is 5 * 5?")
answer = int(sprite.ask("what is 5 * 5?")
if answer == int(25)
int(answer) = sprite.ask("What is 5 * 5?")
What happens if the user enters 12?
The sprite says "Can't wait to vote!"
The sprite says "Not quite ready to retire yet..."
the sprite says nothing
The sprite says both
What happens if the user enters 12?
The sprite says "Can't wait to vote!"
The sprite says "Not quite ready to retire yet..."
the sprite says nothing
The sprite says both
What happens if the user enters maybe?
The if block runs
the elif block runs
The program throws a syntax error
Logic error; nothing happens
How can we solve the logic error caused by users entering something other than yes or no?
Add an else statement
Add more elif statements to test more user input options
Why does the user only get feedback once, even though they are asked to guess three times?
The conditionals are not properly nested inside the loop
They do get feedback 3 times, but it's always the same feedback
rand_num = 5. The user enters 1, 10, and 6. What feedback do they receive?
The sprite says "Too low", then "Too high", then "Too high"
The sprite says "Too low" once
The sprite says "Too high" once
The sprite says "Too high" three times
Do any of these lists contain only one item? (HINT: Pay attention to COMMAS!)
No, all of these lists have more than one item
list_1
list_2
list_4
What happens if you run this loop?
The sprite moves up and down the same amount every time the loop runs
The sprite moves up and down; increasing by 10 each time through the loop
Logic error; the sprite does not move
Syntax error; incorrect data type for move commands
What are the values of min, max, and count_62?
72, 42, 2
42, 72, 0
42, 72, 2
72, 42, 0
What line of code could be used to calculate the average value of list?
average = sum(list)/list.count(list)
average = sum(list)/len(list)
average = len(list)/sum(list)
average = avg(list)
What will happen if the user clicks on megan?
syntax error on line 21
Logic error: jackson says both line
syntax error on line 23
megan says Hello Jackson, the stage changes color jackson says Hello Megan!
Objects can be placed on the stage using a coordinate plane. The origin of this plane is where the x & y axis meet
True
False