Wayground logo

Free Printable Worksheets

Font size

S
M
L
XL
Worksheets

Python: Rock, Scissors, Paper

Total questions: 10

Worksheet time: 5mins

Name
Class
Date
1.
What is the word (command) used to display numbers and text on the screen?
a)
print
b)
input
c)
output
d)
command
2.
What is a variable?
a)
A box(memory location) where you store values
b)
a type of graphics
c)
Data type
d)
a type of memory
3.
What symbol is used in python to assign values to a variable?
a)
equals =
b)
plus + 
c)
forward slash /
d)
asterisk *
4.

Python uses indentation to block code into chunks

a)

True

b)

False

5.
What is the position of the name "Robert" in the following list:
a)
0
b)
1
c)
2
d)
3
6.

Each item in a list has an index. What is the first index in a Python list?

a)

0

b)

1

c)

a

d)

A

7.

Used in conditional statements, same as else if

a)

elif

b)

while

c)

when

d)

elf

8.

When we create a list in Python: t = ["Rock", "Paper", "Scissors"] , what value does "Rock" hold in the list?

a)

1

b)

2

c)

3

d)

0

9.

Why did we need to set player to False

"player = False"

in our Rock, Scissors, Paper game? ....think!!!

a)

we hate people

b)

in order to set the conditions of the game

c)

people aren't real

d)

not this one!

10.

In our Python code for Rock, Scissors, Paper, what line of code was needed for the loop to continue (reset the game)?

a)

from random import randint

b)

player = False

computer = t[randint(0,2)]

c)

t = ["Rock", "Paper", "Scissors"]

d)

player = True

computer = t[randint(0,2)]

e)

restart = game