1994=(x+y)^2+3x+y=(x+y)^2+2(x+y)+1+(x-y)-1=(x+y+1)^2-(y-x+1)
1995+y-x=(x+y+1)^2
RHS is a square of integer number, we must find it by trial such that y-x is as small as possible integer.
nearest square numbers to 1995 are 44^2=1936 and 45^2=2025 (since x and y have to be integers)
using x+y+1=45 ---(1)
y-x=2025-1995=30 ---(2)
from eq. 1 and 2
y=37, and x=7