wayground logo

Free Printable Worksheets

NEW

Font size

S
M
L
XL
Worksheets

Spiral/Variables&Loops/User Input - Codesters

Total questions: 17

Worksheet time: 9mins

Name
Class
Date
1.

The _______ lets us store the text that the user types. We can change that name of that variable to remind us of the value it holds.

a)

input variable

b)

output variable

c)

string

2.

Text that the user enters which is stored in a variable for later use

a)

user input

b)

say command

c)

integer variable

d)

string variable

3.

Debug the code

a)

Add a + between the string and season

b)

Add " " around season

c)

change sprite to season

d)

Delete the " " around "My favorite season is "

4.

We use ______ to combine two strings. If a variable is holding a string value, we can use a ______ to connect the variable and the string.

a)

" "

b)

' '

c)

+

d)

+=

5.

What is the name of the variable that stores the user input?

a)

a

b)

b

c)

c

d)

d

6.

What is the value stored in the user input variable?

a)

a

b)

b

c)

c

d)

d

7.

What is the command that asks the user to type in an answer?

a)

a

b)

b

c)

c

d)

d

8.

a)

a

b)

b

c)

c

d)

d

9.

a)

a

b)

b

c)

c

d)

d

10.

a)

a

b)

b

c)

c

d)

d

11.

The _____ is the number of times that the set of commands will repeat in a loop.

a)

for loop

b)

command

c)

range

d)

counter

12.

How much does the x variable change with each pass through the loop?

a)

-200

b)

40

c)

20

d)

200

13.

How much does the y variable change with each pass through the loop?

a)

-200

b)

40

c)

20

d)

200

14.

What is the turtle’s x-coordinate when the loop has finished?

a)

-200

b)

40

c)

160

d)

200

15.

A _______ is used to repeat a command or a set of commands

a)

range

b)

variable

c)

counter

d)

loop

16.

Debug the program

a)

Add a : at the end of line 9

b)

Remove the indentions on lines 10-13

c)

Add indentions on lines 10-13

d)

This program does not have a bug

17.

Debug the program

a)

Add a : at the end of line 9

b)

Remove the indentions on lines 10-13

c)

Add indentions on lines 10-13

d)

This program does not have a bug