Hi
Let x represent those numbers
Question states***
(x+2)(x-5)= 18
x^2 -3x-10 = 18
x^2-3x-28 = 0
factoring
(x-7)(x+4) = 0 Note:SUM of the outside terms(4x) and the inside terms(-7x) = -3x
(x-7) = 0 x = 7
(x+4) = 0 x = -4
CHECKING our Answers***
9*2 = 18
-2*-9 = 18