7 lines
227 B
Python
7 lines
227 B
Python
# Exercise 4-9 Cube Comprehension
|
|
# Learning Objective: Use List Comprehension to create list of first 10 cubes.
|
|
|
|
cubes = [value**3 for value in range(1, 11)]
|
|
print(cubes)
|
|
|
|
# Unbenownst to me, I had done that already in 4-8. |