MathDB
Concatenating Multiples of a Prime

Source: Tournament of Towns Spring 2016 Junior A-Level

February 23, 2017
number theory

Problem Statement

Let pp be a prime integer greater than 10k10^k. Pete took some multiple of pp and inserted a kk-digit integer AA between two of its neighbouring digits. The resulting integer C was again a multiple of pp. Pete inserted a kk-digit integer BB between two of neighbouring digits of CC belonging to the inserted integer AA, and the result was again a multiple of pp. Prove that the integer BB can be obtained from the integer AA by a permutation of its digits. (8 points) Ilya Bogdanov