Rotations divisible by 37

Let x=37abc‾x = \overline{37abc} be a 55-digit number (digits a,b,c∈{0,…,9}a, b, c \in \{0,\dots,9\}). How many such xx have the property that 37abc‾\overline{37abc}, 37bca‾\overline{37bca}, and 37cab‾\overline{37cab} are all divisible by 3737?

Show hints (2)+
  1. 1000≡1(mod37)1000\equiv1\pmod{37}, so the leading 3737 drops out: each number ≡\equiv its last three digits mod 3737.
  2. You get a cyclic system 26a+10b+c≡026a+10b+c\equiv0, and its two rotations. Count digit-triples satisfying all three.

Answer

Reveal answer →

28

Create a free account to see the full worked solution and track your progress.

Interview format: Market Maker, Hedge Fund Quant

Related questions