Bummer! This is just a preview. You need to be signed in with an account to view the entire instruction.
Well done!
You have completed (UPI) Chapter 2: Introduction to Python!
Instruction
An Example
Letβs consider the following piece of Python code:
# set a splitting point
split_point = 3
# make two empty lists
lower = []
upper = []
# Split numbers from 0 to 9 into two groups,
# one lower or equal to the split point and
# one higher than the split point
for i in range(10): # count from 0 to 9
if i <= split_point:
lower.append(i)
else:
uppe...