To find the equation of a line you need the coordinates of just two points on the line.
For example, if the (x,y) coordinates of the points are (a,b) and (c,d) the slope m of the line is:
m=(d-b)/(c-a). Take either coordinate then the slope-point equation is:
y-b=m(x-a), y=m(x-a)+b=mx-am+b.