7. For what values of $a$ does the equation

$$
[x]^{2}+2012 x+a=0
$$

(where $[x]$ is the integer part of $x$, i.e., the greatest integer not exceeding $x$) have the maximum number of solutions? What is this number?
Answer: 89 solutions at $1006^{2}-20120
\end{array}\right.
$

has the maximum number of integer solutions.

The solution to the first inequality is the interval $\left[-1006-\sqrt{1006^{2}-a} ;-1006+\sqrt{1006^{2}-a}\right]$ under the condition $a \leqslant 1006^{2}$.

The solution to the second inequality for $a>1006^{2}-2012$ is the entire real line, and for $a \leqslant 1006^{2}-2012-$ the set is

$\left(-\infty ;-1006-\sqrt{1006^{2}-2012-a}\right) \cup\left(-1006-\sqrt{1006^{2}-2012-a} ;+\infty\right)$.

Thus, the solutions to the system form:

for $1006^{2}-20121006^{2}$ - 2012. The parameter can be represented as $a=1006^{2}-2012+b, b>0$. The solutions form the interval $[-1006-\sqrt{2012-b} ;-1006+\sqrt{2012-b}]$ and the smaller $b$ is, the larger this interval is.

Since $44^{2}=19360)$. Therefore, for $1006^{2}-2012<a \leqslant$ $1006^{2}-1936$ the number of integer solutions is equal to the number of integer points on the interval $[-1006-44 ;-1006+44]$, i.e., 89.

For $a=1006^{2}-2012$, the point $k=-1006$ disappears from the solution. As $a$ further decreases, new integer points $-1006 \pm 45$ will first appear in the set

$\left[-1006-\sqrt{1006^{2}-a} ;-1006-\sqrt{1006^{2}-2012-a}\right) \cup\left(-1006-\sqrt{1006^{2}-2012-a} ;-1006+\sqrt{1006^{2}-a}\right]$ at $a=1006^{2}-45^{2}=1006^{2}-2025$. However, at this point, integer points lying on the interval $\left[-1006-\sqrt{1006^{2}-2012-a} ;-1006+\sqrt{1006^{2}-2012-a}\right]=$ $[-1006-\sqrt{13} ;-1006+\sqrt{13}]$, i.e., 7 points: $-1006 ;-1006 \pm 1 ;-1006 \pm 2 ;-1006 \pm 3$, must be excluded from the solution. Since further decreasing $a$ reduces the total length of the solution set, the number of integer points will also decrease.