When we are given two points and we have to write the equation that passes through the two points, we can first find the slope. Let's say (3,1) is \((x_{1}, y_{1})\) and (0,10) is \((x_{2}, y_{2})\). Using two points, we can use find the slope with the following formula.

\(\displaystyle{\frac{{{\left({y}{2}-{y}{1}\right)}}}{{{\left({x}{2}-{x}{1}\right)}}}}\)

Replace these variables with the values.

\(\displaystyle{\frac{{{\left({10}-{1}\right)}}}{{{\left({0}-{3}\right)}}}}=-{3}\)

-3 is the slope. Next, we have to find the y-intercept. We can plug in the values that we know using the following formula:

\(y = mx+ b\)

\(y = -3x + b\)

Now we can choose one of the points, and plug in the values in the equation above. Let's use (0,10).

\(10 = -3(0) + b\)

\(b = 10\)

(Note: The point (0,10) is already on the y-axis, meaning that 10 is the y-intercept. We didn't need to do the step above for this specific problem.)

So the complete equation of the line that passes through the two points is:

\(y = -3x + 10\)