The equation of a line is given as: y = mx +c. Write a program that asks the user for the start and end points of a line and calculates values for m and c:

m = The slope of the line (y2 – y1) / (x2 – x1)

c = The intercept (where the line intersects the y axis (i.e. Where x = 0)

Here’s my solution for it:

Continue reading