Solution:
The slope-intercept form of a line with slope m and y-intercept b is given by the following formula:

On the other hand, the slope m is given by the following equation:

where (X1,Y1) and (X2,Y2) are points on the line. In this case, we can take the points:
(X1,Y1) = (1,2)
(X2,Y2) = (-1,-1)
replacing this data into the slope equation, we get:

thus, the slope of the line would be:

now, replacing this into the slope-intercept form of the line we get:
EQUATION 1

We only need to find the y-intercept b. For that, take any point on the line, for example (x,y) = (1,2), and replace it into the previous equation:

this is equivalent to:

solving for b, we get:

that is:

finally, replacing this into the EQUATION 1, we get:

then, the slope-intercept form of a line with the points (1,2) and (-1,-1) would be:
