2023 SSMO Accuracy Round Problems/Problem 2

Problem

Suppose that the average of all $n$-digit palindromes is denoted by $P_{n}$ and the average of all $n$-digit numbers is denoted by $N_{n}.$ Find $\left\lfloor\sum_{n=1}^{100}(P_{n}-N_{n})\right\rfloor.$

Solution