Font size
WorksheetsPython review 1
Total questions: 23
Worksheet time: 11mins
is integer a number
true
false
chose which is a floating point
14
15.5
chose a string
"tim"
"tim
'tim'
"tim
tim
What in the name of the variable in this Python code?
name
input
("What is your name")
Which of these is not an arithmetic operator?
+
-
*
=
What will be the output?
name = "Dave"
print (name)
Dave
'Dave'
name
(name)
It displays an output
The punctuation requirements for printing a string in Python are:
( ) , ! and " "
( ) and !
( ) and " "
" " and !
What can be used to store information and values so that it can be used later?
Graphic
Variable
Output
What would print (10 + 16) produce?
10
16
24
26
What is a input?
To plug in something.
A function that allows us to ask the user to enter some data.
Data displayed on a screen.
A function
name=input("What is your name? ")
print("Your name is " + name)
What will be displayed if the user types in "Bob"?
Your name is name
name
Bob
Your name is Bob
print(3*4+5)
Code for
Five is greater than two!
if 5 > 2:
print("Five is greater than two!")
if 5 = 2:
print("Five is greater than two!")
if 5 > 2: Print("Five is greater than two!")
Insert the missing part of the code below to output
_________________ "My name is ".
The output of the program
x = 4
x = "Sally"
print(x)
four
Saly
Sally
This operator checks to see if one value is the same as the other value
==
!=
>
<
What is the output of the following code snippet?
x = 5
if x > 3:
print("Greater than 3")
else:
print("Less than or equal to 3")
Greater than 3
Less than or equal to 3
Invalid syntax
No output
