If $f:Z\rightarrow Z$ is defined as $f(x)=x^2+ax+b$ then the values of $a$ and $b$ are ?

$\begin{array}{1 1}a\in Z,\:\:b\in Q-Z \\ a,b \in Z \\ b\in Z,\:\:a\in Q-Z \\a,b\in Q-Z \end{array}$

Since $f:Z\rightarrow Z$, $x\:and\:f(x)$ take only integer values.
$\Rightarrow f(0)\:and\:f(1)$ are also integers.
$\Rightarrow\:f(0)=b\:\:and\:\:f(1)=a+b+1$ are integers.
$\Rightarrow \:a,b \in Z$