Answer:
y=-x+18
Explanation:
Equation of a line
A line can be completely defined by two points. Suppose we know the line passes through points A(x1,y1) and B(x2,y2).
The equation for a line can be written as:
![y=mx+b](https://img.qammunity.org/2021/formulas/mathematics/middle-school/yj5waqmoy4i54laybzhhshd88hyo5w5rj5.png)
Where m is the slope and b is the y-intercept. Both values can be determined by using the coordinates of the given points.
First, determine the slope with the equation:
![\displaystyle m=(y_2-y_1)/(x_2-x_1)](https://img.qammunity.org/2021/formulas/mathematics/high-school/41kulvff1pgimoc7unwlsr8pc5vgedtyrp.png)
The points are: A(15,3) B(3,15)
![\displaystyle m=(15-3)/(3-15)=(12)/(-12)=-1](https://img.qammunity.org/2021/formulas/mathematics/college/makbbatroebjgakf80dg65x5q05hfaxctb.png)
The equation of the line can be written as:
![y=-x+b](https://img.qammunity.org/2021/formulas/mathematics/high-school/k17ps61s98vr383i2klj3u87ebg1w2vdqm.png)
Now, use any point to determine the value of b. Substitute (15,3):
![3=-15+b](https://img.qammunity.org/2021/formulas/mathematics/college/10i7pdlgmmkl43rzpu08ygjl15mfokjbcn.png)
Solve for b:
b=18
The equation of the line is
y=-x+18
The slope is -1 and the y-intercept is 18.