<s>[INST] Minimum value of $4$-digit number divided by sum of its digits? If x was a positive 4 digit number and you divide it by the sum of its digits to get the smallest value possible, what is the value of x? For example (1234 = 1234/10)
I got 1099 as my answer however I don't know if this is right or how to prove it.
 [/INST] Write the $4$-digit number as $x = 1000a+100b+10c+d$, where $a,b,c,d$ are integers from $0$ to $9$ (and $a \neq 0$.)
You want to minimize $A = \dfrac{1000a+100b+10c+d}{a+b+c+d}$, which can be written as
$$
\begin{align*}
A &= \dfrac{999a+99b+9c}{a+b+c+d}+1\\
&\geq \dfrac{999a+99b+9c}{a+b+c+9} + 1 & \text{(since the numerator} > 0\text{, set } d = 9)\\
&= \dfrac{990a+90b-81}{a+b+c+9} + 10\\
&\geq \dfrac{990a+90b-81}{a+b+9+9} + 10 & \text{(since the numerator} > 0\text{, set } c = 9)\\
&= \dfrac{900a-18\times90-81}{a+b+9+9} + 100\\
&= \dfrac{900a-1701}{a+b+18} + 100\\
&\geq \dfrac{900\times 1-1701}{1+b+18} + 100 & \text{(since the } \textbf{denominator} > 0\text{, set } a = 1)\\
&\geq \dfrac{900-1701}{1+0+18} + 100, & \text{(since the numerator} < 0\text{, set } b = 0)\\
\end{align*}
$$
and the minimum attains when $x = 1099$.
</s>