Each number in the code can be 1 of 10 numbers.
The total number of possible combinations is 10 * 10 * 10 * 10 = 10,000
The probability of getting 1234 would be 1/10,000
20,000 miles because 1 mile and 1,000 miles are too small and 100,000 is too big. Hope that this helped!