xy = -40 (1)
x + y = 16 (2)
y = 16 -x
substitute into (1)
x (16-x) = -40
16x - x^2 + 40 = 0
x^2 -16x -40 = 0
x = (16 +/- SQRT(256+160))/2
x = 18.2 or -2.2 which are the the two numbers you are looking for
-21, 27
-22
-9.22043 and 18.22043 (to 5 dp).
-17
The numbers are 6 and 28
20
-17
-30
-127
3452
-936
-117
17
-21, 27
22
137
-43