🦘 Math Kangaroo Grade All Felix 1-2 Ecolier 3-4 Benjamin 5-6 Kadett 7-8 Junior 9-10 Student 11-12 ⇄ switch contest
2019 Math Kangaroo

Problem 19

Problem 19 · 2019 Math Kangaroo Stretch
Number Theory place-valuecareful-counting

The pages of a book are numbered with 1, 2, 3, 4, 5 and so on. The digit 5 appears exactly 16 times. What is the maximum number of pages the book can have?

Show answer
Answer: B — 64
Show hints
Hint 1 of 2
Count where the digit 5 shows up as you list page numbers 1, 2, 3, ...
Still stuck? Show hint 2 →
Hint 2 of 2
The block 50-59 alone contributes ten 5s (the tens digit); add those to the single 5s like 5, 15, 25, ...
Show solution
Approach: count occurrences of the digit 5
  1. Up to 49 the 5s appear at 5, 15, 25, 35, 45: five of them.
  2. The block 50-59 has a 5 in every tens digit: ten more, plus the extra units-5 in 55, reaching the 16th by page 59.
  3. Pages 60-64 add no new 5s, but page 65 would add a 17th.
  4. So the most pages with exactly sixteen 5s is 64 (B).
Mark: · log in to save