Practice Range and Lists - 11.3 | 11. More about range() | Data Structures and Algorithms in Python
K12 Students

Academics

AI-Powered learning for Grades 8–12, aligned with major Indian and international curricula.

Academics
Professionals

Professional Courses

Industry-relevant training in Business, Technology, and Design to help professionals and graduates upskill for real-world careers.

Professional Courses
Games

Interactive Games

Fun, engaging games to boost memory, math fluency, typing speed, and English skillsβ€”perfect for learners of all ages.

games

Practice Questions

Test your understanding with targeted questions related to the topic.

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.

Practice 4 more questions and get performance evaluation

Interactive Quizzes

Engage in quick quizzes to reinforce what you've learned and check your comprehension.

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.

Solve 2 more questions and get performance evaluation

Challenge Problems

Push your limits with challenges.

Question 1

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

πŸ’‘ Hint: Use range to define how many times to loop.

Question 2

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.

Challenge and get performance evaluation