Answer:
There's a formula: 
Step-by-step explanation:
You take 2 points from the line, and plug it in.
For example, if the 2 points on a line were (1, 4) and (2, 7) you would set it up like this...

...then solve the top and then solve the bottom so it becomes a fraction:

One thing is that is that if the Y1 is from the <em>first</em> coordinate, then X1 should also be form the 1st coordinate