how would i find a equation for solutions given of x=5 and x=-3?

In algebra, you often end up with something like

(x + 17)(x - 25) = 0
You solve that for x by setting each factor = 0.
x + 17 = 0 and x - 25 = 0
x = -17 x = 25

Just do that in reverse.

x = 5 and x = -3
x - 5 = 0 x = 3
(x - 5)(x + 3) = 0

Now use FOIL to get ...

x^2 - 2x - 15 = 0