Another method (though just a bit more difficult than x-factor's answer)
x-y=16
x = 16+y
xy = 23
(16+y)y=23
y^2 +16y -23=0 use quadratic formula to find y = 1.3273 or -17.3273
then x = 17.3273 or -1.3273
then x^2 + y^2 = 302 (pick either x,y pair above....same result)