Maths Olympiad Prep

Track / Stage 2 / 233 of 240 #473 of 2444

Problem 473

Number theory Difficulty 2.8 Multiple choice CEMC Gauss (Grade 7) · Canada · 2015

A palindrome is a positive integer that is the same when read forwards or backwards. The numbers 101 and 4554 are examples of palindromes. The ratio of the number of 4-digit palindromes to the number of 5-digit palindromes is

Pick one

Next problem →

Official solution

Solution 1

Every 4-digit palindrome is of the form abbaabba, where aa is a digit between 1 and 9 inclusive and bb is a digit between 0 and 9 inclusive (and bb is not necessarily different than aa).

Every 5-digit palindrome is of the form abcbaabcba, where aa is a digit between 1 and 9 inclusive, bb is a digit between 0 and 9 inclusive (and bb is not necessarily different than aa), and cc is a digit between 0 and 9 inclusive (and cc is not necessarily different than aa and bb).

That is, for every 4-digit palindrome abbaabba there are 10 possible digits cc so that abcbaabcba is a 5-digit palindrome.

For example if a=2a=2 and c=3c=3, then the 4-digit palindrome 23322332 can be used to create the 10 5-digit palindromes: 23032,23132,23232,23332,23432,23532,23632,23732,23832,2393223032, 23132, 23232, 23332, 23432, 23532, 23632, 23732, 23832, 23932.
Thus, for every 4-digit palindrome abbaabba, there are exactly 10 5-digit palindromes abcbaabcba and so the ratio of the number of 4-digit palindromes to the number of 5-digit palindromes is 1:101:10.

Solution 2

Every 4-digit palindrome is of the form abbaabba, where aa is a digit between 1 and 9 inclusive and bb is a digit between 0 and 9 inclusive (and bb is not necessarily different than aa).

There are 9 choices for the first digit aa and, for each of these choices, there are 10 choices for the second digit bb or 9×10=909\times10=90 choices for the first two digits abab.

Once the first two digits of the 4-digit palindrome are chosen, then the third and fourth digits are also determined (since the third digit must equal the second and the fourth must equal the first).

That is, there are 90 4-digit palindromes.

Every 5-digit palindrome is of the form defeddefed, where dd is a digit from 1 to 9 inclusive and ee is a digit from 0 to 9 inclusive (and ee is not necessarily different than dd) and ff is a digit from 0 to 9 inclusive (and ff is not necessarily different than dd and ee).

There are 9 choices for the first digit dd and 10 choices for the second digit ee and 10 choices for the third digit ff or 9×10×10=9009\times10\times10=900 choices for the first three digits defdef.

Once the first three digits of the 5-digit palindrome are chosen, then the fourth and fifth digits are also determined (since the fourth digit must equal the second and the fifth must equal the first).

That is, there are 900 5-digit palindromes.
Thus, the ratio of the number of 4-digit palindromes to the number of 5-digit palindromes is 90:90090:900 or 1:101:10.

Source: CEMC, University of Waterloo, licensed CC-BY-NC-4.0. Statement reproduced verbatim; metadata (topic, difficulty, ordering) added by this project.