CoursesCSS StudioExamplesGATECompaniesPrepMentora
Programs/Logic building/Phase 2 - Level 1: Basic Looping

6 / 14

Next
1. Print Numbers from 1 to 102. Print All Even Numbers Between 1 and 1003. Sum of First N Natural Numbers4. Print the Factorial of a Given Number5. Print All Odd Numbers Between 1 and 1006. Print Numbers from 10 Down to 17. Print Multiplication Table8. Sum of All Even Numbers Up to N9. Sum of All Odd Numbers Up to N10. Product of Digits11. Count Numbers Divisible by 312. Print Multiples of 5 Up to N13. Sum of Squares Up to N14. Print Alternating Numbers

Phase 2 - Level 1: Basic Looping

  1. 01Print Numbers from 1 to 10
  2. 02Print All Even Numbers Between 1 and 100
  3. 03Sum of First N Natural Numbers
  4. 04Print the Factorial of a Given Number
  5. 05Print All Odd Numbers Between 1 and 100
  6. 06Print Numbers from 10 Down to 1
  7. 07Print Multiplication Table
  8. 08Sum of All Even Numbers Up to N
  9. 09Sum of All Odd Numbers Up to N
  10. 10Product of Digits
  11. 11Count Numbers Divisible by 3
  12. 12Print Multiples of 5 Up to N
  13. 13Sum of Squares Up to N
  14. 14Print Alternating Numbers

Print Numbers from 10 Down to 1

Print numbers from 10 down to 1.

BeginnerPhase 2 - Level 1: Basic LoopingExample 6 of 14
print-numbers-from-10-down-to-1.py
1# Print numbers 10 to 1
2for i in range(10, 0, -1):
3 print(i)

Output

10
9
8
7
6
5
4
3
2
1

What's going on

Use range with negative step.

Key Concepts:

range(10, 0, -1) counts backwards
Start: 10, End: 0 (exclusive), Step: -1
Prints 10, 9, 8, ..., 1

🔗Related Content

  • 📖

    Phase 2 - Learn Concepts

    Review Phase 2 concepts and explanations

  • 📝

    Phase 2 - Quiz

    Test your Phase 2 understanding with quiz questions

  • 💻

    Phase 2 - All Practice Problems

    Explore all practice problems for Phase 2

  • 🎓

    Master Your Logic Building - Complete Course

    Browse all phases and tutorials

  • 🧠

    Logic Building Overview

    Learn about the complete logic building curriculum

PreviousPrint All Odd Numbers Between 1 and 100NextPrint Multiplication Table

On this page

CodeOutputExplanation
Up nextPrint Multiplication Table
Schoolabe

Learn, Practice, Ace Coding

ExamplesCompaniesTutorialsCSS StudioDSA VisualizersQuizInterview PrepMentoraCareer QuestGATE CS prepGATE CS 2027 study planJob ReadyInternships
AboutContactCareersAffiliate programBlog
DocumentationAPI ReferenceCommunitySupport
Privacy PolicyTermsRefund PolicyCookie Policy

© 2026 Schoolabe