Back

Python Data Structures Practice / 1. List Comprehension - Squares

00:00
1/20

1. List Comprehension - Squares

Medium

Create a list of squares of numbers from 1 to 10 using list comprehension.

  • 1

    List comprehension syntax: [expression for item in iterable]. Use range(1, 11) and square each number.

PYTHON PLAYGROUND
PYTHON PLAYGROUND
⏳ Loading editor…