1001^2
=(1000+1)^2
=1000^2+2*1000+1^2
=1002001
2009^2-2008*2010
=2009^2-(2009-1)*(2009+1)
=2009^2-(2009^2-1^2)
=1