We will investigate the how to formulate an equation of a straight line.
All equation of straight line have a general slope-intercept format given as follows:

Where,

To completely define any equation of a line we need to two points OR we need a point and one of the parameters ( m or c )!
We will suppose that we have two points ( A and B ) as follows:

To determine the value of parameter slope ( m ) we utilize the following general formula:

We simply plug in the respective values of the coordinates ( A and B ) in the general formula above and solve for ( m ).
Once we have evaluated the value of parameter ( m ) in the previous step we will determine the value of parameter ( c ) i.e y-intercept.
To determine the value of ( c ) we need only one point! You can choose either point ( A or B )!
Lets assume that we chose point ( A ). We will then plug in the values of coordinates and the value of parameter ( m ) into the general form of the equation as follows:

In the above form all are known quantities and only ( c ) is unknown! We can manipulate the above expression and solve for ( c ) as follows:

Then we have obtained the value of ( c ) as well!
We can then write down the complete equation of the straight line by using the calculated values of ( m and c ) into the general equation and express in form:

Where,
