True or False: Python program code is executed line by line, from first to last line.
True
True or False: Every line of code, no matter what kind, is always evaluated left to right.
False
Expressions are evaluated left to right but assignments are evaluated right to left.
What expression/s are equivalent to this expression: a + b * c
1 and 5 are equivalent.
What expression/s are equivalent to this expression: a = b * c
1 and 3 are equivalent
When it comes to coding styles, Python will…
Why should programmers adhere to coding conventions and style recommendations?
For what parts are there style recommendations?
What are comments and how are they indicated?
What are the main data types used in this semester?
Choose the correct statement/s.
Choose the correct statement/s.
Choose the correct statement/s.
Which of the following statements are true for static typing and which are true for dynamic typing?
What happens in Python when a value is assigned to a variable that doesn’t exist yet?
the variable is created and the value is assigned to it
True or False: Variable names are case sensitive.
True
Which of the following variable names are valid by conventions and rules?
What is the output of this code?
x = 13
y = x
x = 2 * y
y = 0
print(x)
26
What is the output of this code?
x = 13
y = x
y = 0
There is no output, since there is no print()-function.
What data type does the input()-function return?
String
What is the output of this code?
x = 13
#x = 2 * x
y = 0
print(x)
13
What is the output of this code?
x = 13
x = 2 # * x
y = 0
print(x)
2