Python Practice › Loop Programs › Program 72

Product of the first 10 numbers

EasyLoop Programs · 72 of 90

Write a Python program to find the product of the first 10 natural numbers.

Advertisement
Output
3628800

Approach

  1. Start at 1 and multiply by each number.

Solution

Python
product = 1for n in range(1, 11):    product *= nprint(product)
Output
3628800
Note

This is 10! (10 factorial).

Learn the concept

New to this topic? Read the lesson, then come back.

More loop programs

← All 90 Loop Programs

Leave a Comment