AI InterviewSearch…Search problems, topics, or pages…Ctrl KGet started
Hardtrailing zerosfactorial

~120s

Zeros at the end of a product

How many zeros are there at the end of the product 10 × 20 × 30 × … × 100?

Show the answer and the worked solution

Correct answer: C.

12

Worked solution

  1. 10 × 20 × … × 100 = 10¹⁰ × (1 × 2 × … × 10) = 10¹⁰ × 10!.
  2. 10¹⁰ ends in ten zeros.
  3. 10! = 3,628,800 has ⌊10/5⌋ = 2 trailing zeros.
  4. Total = 10 + 2 = 12.

Answer: 12.

The idea

Pull out the common factor of 10 from every term first — it converts the problem into a power of ten times a plain factorial, and only the factorial needs the factor-of-5 count.

Shortcut. Count fives term by term: each of the ten terms holds one, and 50 and 100 each hold a second, so 10 + 2 = 12; twos are plentiful.

Common trap. 11 — counting the zeros printed in the terms (one each in 10 to 90, two in 100); the extra five in 50 pairs with a spare 2 to make a twelfth.

Zeros at the end of a product — Aptitude Question

Zeros at the end of a product: How many zeros are there at the end of the product 10 × 20 × 30 × … × 100? Answer and worked solution on CodeKairo.

Question

How many zeros are there at the end of the product 10 × 20 × 30 × … × 100?

Options

  1. 10
  2. 11
  3. 12
  4. 13
Show the answer and the worked solution

Correct answer: C. 12

Worked solution

  1. 10 × 20 × … × 100 = 10¹⁰ × (1 × 2 × … × 10) = 10¹⁰ × 10!.
  2. 10¹⁰ ends in ten zeros.
  3. 10! = 3,628,800 has ⌊10/5⌋ = 2 trailing zeros.
  4. Total = 10 + 2 = 12.

Answer: 12.

The idea

Pull out the common factor of 10 from every term first — it converts the problem into a power of ten times a plain factorial, and only the factorial needs the factor-of-5 count.

Shortcut. Count fives term by term: each of the ten terms holds one, and 50 and 100 each hold a second, so 10 + 2 = 12; twos are plentiful.

Common trap. 11 — counting the zeros printed in the terms (one each in 10 to 90, two in 100); the extra five in 50 pairs with a spare 2 to make a twelfth.

All Number System questions · placement mock tests