WorksheetsPython Syntax
Total questions: 14
Worksheet time: 9mins
Name
Class
Date
1.
includes numbers and booleans
a)
data types
b)
whitespace
c)
modulo
d)
comments
2.
used to structure code in Python
a)
whitespace
b)
comments
c)
booleans
d)
variables
3.
runs code line by line and checks for errors
a)
interpreter
b)
variable
c)
modulo
d)
boolean
4.
Used to create exponents
a)
**
b)
"""
c)
%
d)
#
5.
stores a piece of data, and gives it a specific name
a)
variable
b)
whitespace
c)
interpreter
d)
modulo
6.
returns the remainder from division
a)
modulo
b)
exponments
c)
boolean
d)
variables
7.
surrounds multi-line comments
a)
"""
b)
**
c)
#
d)
%
8.
a line of text that Python won't try to run as code
a)
comment
b)
modulo
c)
variable
d)
boolean
9.
symbol used for modulo
a)
%
b)
&
c)
#
d)
**
10.
a data type than can have one of two values: True or False
a)
boolean
b)
variable
c)
modulo
d)
interpreter
11.
changing the value of a variable
a)
reassign
b)
comment
c)
modulo
d)
boolean
12.
Used to make comments
a)
#
b)
%
c)
**
d)
()
13.
The correct way to write a variable in Python?
a)
my_variable = 10
b)
my variable = 10
c)
my_variable is 10
d)
my_variable: 10
14.
102 = 100
Which of the following is used in Python to calculate ten squared?
Which of the following is used in Python to calculate ten squared?
a)
10 ** 2
b)
10 * 2
c)
10 % 2
d)
10 ** 10
100 %
