For how many values of x, this expression is an integer?

$y = \dfrac{24x}{24+x}$

I can't think of a way to split these terms so as to get an estimate of number of integral solutions possible.

Edit: Positive values of x


Solution 1:

We must have $24+x\mid 24x\Rightarrow24+x\mid24x+24^2-24^2=24(24+x)-24^2$ which means that $24+x\mid 24^2$. But, $24^2$ has many divisors. Since $24^2=2^6\cdot 3^2$ it has $(6+1)(2+1)=21$ divisors (if you let negative divisors then it has 42!)
So, if $x$ is an integer you have to solve $42$ equations.
For example $24+x=1, 24+x=-1, 24+x=2$ etc. There $42$ values of $x$.

Solution 2:

If $x$ and $y$ are integers, with $x$ positive, such that $y=\frac{24x}{24+x}$, then also $$y=\frac{24x}{24+x}=\frac{24(24+x)-24^2}{24+x}=24-\frac{24^2}{24+x}.$$ So this boils down to counting the divisors of $24^2$ that are greater than $24$.