Browse · MathNet
PrintSelection and Training Session
Belarus counting and probability
Problem
Let be the number of all -digit natural numbers each consisting only of the digits (but not necessarily all of them) such that the sum of no two neighboring digits equals . Determine whether and are divisible by . (I. Kozlov)
Solution
Let , , , be the quantities of the numbers satisfying the given condition which end by the digits , , , respectively. Then . By condition, Summing all the equalities, we get Note that modulo we have , , , , , , , , , . Now we see that residues of the numbers modulo repeat periodically with period . So, iff or , whence , .
Final answer
g(2010) is not divisible by 11; g(2011) is divisible by 11.
Techniques
Recursion, bijectionRecurrence relations