NEW
Font size
WorksheetsPython - Week 1 and 2 recap
Total questions: 9
Worksheet time: 4mins
Python is an example of a:
Text-based programming language
Visual-based programming language
Block-based programming language
Language written in JavaScript
What will the output be from the following code? Print (“Hello world!”)
SyntaxError
“Hello world!”
Hello world!
Print (Hello world!)
What is the syntax error with this code:
print(“Hello World”);
No brackets around "Hello World"
Speech marks are not needed
Colon is not needed
print is spelt incorrectly
Print has a capital P
The correct way to write a variable in python?
my_variables=10
my_variable:10
my variable=10
my_variable is 10
If x1=9. What type is 'x'?
int
float
I set the variable 'pi' to equal 3.1415926535. What type is it?
int
float
integer=45.5
print(type(integer))
<class 'int'>
<class 'float'>
45.5
45
Which statement correctly assigns "Sophie" to the variable name?
name = print( "Sophie")
input("Sophie")
name = "Sophie"
name = input("Sophie")
