Problem

Source: BMO Shortlist 2022, N3

Tags: number theory



For every natural number $x{}$, let $P(x)$ be the product of the digits of the number $x{}$. Is there a natural number $n{}$ such that the numbers $P(n)$ and $P(n^2)$ are non-zero squares of natural numbers, where the number of digits of the number $n{}$ is equal to (a) 2021 and (b) 2022?