Practice Range And Lists (11.3) - More about range() - Data Structures and Algorithms in Python
Students

Academic Programs

AI-powered learning for grades 8-12, aligned with major curricula

Professional

Professional Courses

Industry-relevant training in Business, Technology, and Design

Games

Interactive Games

Fun games to boost memory, math, typing, and English skills

Range and Lists

Practice - Range and Lists

Learning

Practice Questions

Test your understanding with targeted questions

Question 1 Easy

What does range(3) produce?

💡 Hint: Think about starting from 0 up to but not including 3.

Question 2 Easy

What is the output of range(1, 5)?

💡 Hint: Start at 1 and stop before 5.

4 more questions available

Interactive Quizzes

Quick quizzes to reinforce your learning

Question 1

What will range(1, 10, 2) return?

1
2
3
4
5
1
3
5
7
9
0
1
2
3
4

💡 Hint: Check how many steps each number increases.

Question 2

True or False: range(4) includes the number 4.

True
False

💡 Hint: Remember if the end number is included in the range.

2 more questions available

Challenge Problems

Push your limits with advanced challenges

Challenge 1 Hard

Create a program that uses range to print the first 10 square numbers.

💡 Hint: Use range to define how many times to loop.

Challenge 2 Hard

Write a script that generates a list of even numbers from 0 to 100 using the range function.

💡 Hint: Think about the correct start, stop, and step sizes.

Get performance evaluation

Reference links

Supplementary resources to enhance your learning experience.