Problem

Source: INMO 2020 P3

Tags: number theory



Let $S$ be a subset of $\{0,1,2,\dots ,9\}$. Suppose there is a positive integer $N$ such that for any integer $n>N$, one can find positive integers $a,b$ so that $n=a+b$ and all the digits in the decimal representations of $a,b$ (expressed without leading zeros) are in $S$. Find the smallest possible value of $|S|$. Proposed by Sutanay Bhattacharya

HIDE: Original Wording As pointed out by Wizard_32, the original wording is: Let $X=\{0,1,2,\dots,9\}.$ Let $S \subset X$ be such that any positive integer $n$ can be written as $p+q$ where the non-negative integers $p, q$ have all their digits in $S.$ Find the smallest possible number of elements in $S.$