When does end in “11”?

Let x be uniformly random from 1 to 1012. We want the probability that the decimal representation of ends in 11.

1. Reduce to the last two digits

Ending in “11” means exactly:

x³ ≡ 11 (mod 100)

So the whole 12-digit range is irrelevant except for how often each residue modulo 100 appears. We only need to inspect x mod 100.

Click any residue to see its cube modulo 100.

2. Solve the congruence

Modulo 4
11 ≡ 3 (mod 4)

So x³ ≡ 3 (mod 4), which forces:

x ≡ 3 (mod 4)
Modulo 25
x³ ≡ 11 (mod 25)

The solution is:

x ≡ 21 (mod 25)
Combine them

The residues congruent to 21 mod 25 are:

21, 46, 71, 96 (mod 100)

Only 71 is also congruent to 3 mod 4.

x ≡ 71 (mod 100)

3. Final probability

Exactly 1 residue out of 100 works.

1 good residue ÷ 100 residues
1/100 = 1%

Since 1012 is divisible by 100, each residue modulo 100 occurs exactly 1010 times.

Check: 71³ = 357911, which ends in 11.