3. Given that for every pair of real numbers $x, y$, the function $f$ satisfies $f(x)+f(y)=f(x+y)-x y-1$. If $f(1)=1$, then how many integers $n$ satisfy $f(n)=$ $n(n \in \mathbf{Z})$?
3. Let $y=1$, we get $f(x)+f(1)=f(x+1)-x-1$, which means $f(x+1)=f(x)+x+2$. Let $x=0$, we get $f(1)=$ $f(0)+2$. Given $f(1)=1$, we know $f(0)=-1$. When $n \in \mathbf{N}$, $f(n)=\sum_{k=1}^{n}[f(k)-f(k-1)]+f(0)=\sum_{k=1}^{n}(k+1)+$ $f(0)=\frac{1}{2} n(n+3)-1$. Similarly, $f(-n)=-\frac{1}{2} n(-n+3)-1$. Therefore, $f(n)=\frac{1}{2} n(n+3)-1, n \in \mathbf{Z}$. Let $f(n)=n$, solving gives $n=-2$ or $n=1$, hence the number of solutions for $n$ is 2.