Merge numbers to a new number and find digit on position \(n\)
The number you are constructing is related to the base 10 Champernowne constant, except that the Champernowne is a real number that starts with 0.123... while your "number" is an integer with an infinite number of digits.
In Mathematica, the Champernowne constant in base 10 is given by ChampernowneNumber[]
. To get the 10,000 digit, just use RealDigits
:
RealDigits[ChampernowneNumber[], 10, 1, -10000][[1, 1]]
7