Code Writer
Level 3, 2026-08-28
Answers should be legal Python code, including indentation. Use the underscore _ to show a space.
Special functions: print(), range(), sqrt(), str()
Assume you have 2 lists of numbers with 18 elements each: B and Q. Add the 8th elements of the lists together.

Use: variables[1]

Test Using:
B = [1,2,3,...,18], Q = [1,2,3,...,18]
Use a loop to multiply the numbers from 9 to 28

Use: variables, loops[2]
Assume you have a list of names, Z. Write code to count the number of times the name "Julie" appears in the list.

Use: variables, loops, if[2]

Test Using:
Z = []
Z = ['Julie']
Z = ['Julie','Edward','Julie','Julie']
Assume you have a non-empty list of scores E for your math class. Calculate the mean of the scores.

Use: variables, loops[3]

Test Using:
E = [10]
E = [1,2,3,4,5]
E = [93,92,54]
Assume you have a non-empty list of scores Y for your math class. Calculate the sum of the scores.

Use: variables, loops[3]

Test Using:
Y = [10]
Y = [1,2,3,4,5]
Y = [93,92,54]
Set a variable to one value then change that value

Use: variables[1]
Print your first name

Use: [1]
A rectangle has sides of 5 and 4. Create variables for the sides of the shape and then calculate its perimeter

Use: variables[2]