For how many integer values of $a$ does the equation $$x^2 + ax + 8a = 0$$ have integer solutions for $x$?
Using the quadratic formula, there are 12 integer values of a that work.