NEW
Font size
WorksheetsPython II Lesson 2
Total questions: 12
Worksheet time: 6mins
Which symbol is floor division?
//
/
*
)
Which symbol represents multiplication?
*
/
+
**
Which symbol is used for exponents?
**
-
_
//
Which symbols surround a list?
[]
{}
()
||
print(3*4+5)
Which function changes a string to a float?
float()
num()
print()
change()
A list is changeable and unordered
True
False
List items have an index number. In the following list, which item has the index number of 3?
["John", "Harry", "Jesse", "John", "Harry", "Harry"]
"John"
"Harry"
"Jesse"
"John"
The list needs one more name added to the end - "Felipe". Which piece of code below would do this?
nameList = ["John", "Harry", "Jesse", "John", "Harry", "Harry"]
nameList.append(Felipe)
append(nameList,"Felipe")
nameList.append["Felipe",7]
nameList.append("Felipe")
What is the answer to?
print(10 % 4)
1
3
2
4
