NEW
Font size
WorksheetsPython Ch 1 Review
Total questions: 23
Worksheet time: 11mins
To execute a Python program, you need a Python interpreter.
True
False
Python is the fastest growing programming language:
True
False
What is IDE?
Integrated Development Environment
Implicit Deployment Environment
Interrogated Development Environment
"hello"
String
Integer
Float
Word
What will be the output from the following Python code?
print("3+4")
7
3+4
34
SyntaxError
What will the output be from the following Python code?
print(3+4)
3+4
7
SyntaxError
print(3+4)
What value results from the following expression: print("=" * 5)
=10
Integer
=====
Error
What value results from the following expression: print( (1 + 4) * 2)
9
10
5
Error
Why did Guido van Rossum call his programming language Python?
He thinks Pythons were cool
He couldn't think of anything else
A friend suggested it
He loves Monty Python
What can a variable not start with?
A special character
A capital letter
A number
A lower case letter
What do we use at the start of a comment line?
@
#
"
*
What arithmetic operations does // perform in Python?
Remainder
Division
Floor Division
Modulus
Which of these is true?
A syntax error will stop a program running
A logic error will stop a program running
A syntax error will let the program run but may have unexpected outcomes
The program will always show an error message for a logic error
By default any data inputted by the user is of data type string in python.
True
False
Looking at the code, what is the output?
54
2331
var1+var2
Error
Which answer is the correct output?
print(5.0 * 5)
25
10
10.0
25.0
What will be the output?
print(int(3.98))
3.98
Error
3
4
print(3*4+5)
What does the following code do? myAge = int (myAge)
Converts the var (variable) myAge to a string
Converts the var (variable) myAge to a integer
Converts the var (variable) myAge from a integer to a string
Converts the var (variable) myAge to if statement
