What is the equation of the line?

A line has an equation of a form,
[tex]y=ax+b[/tex]
From a graph we can pick two points on the line, say A and B where,
[tex]A(x_1,y_2),B(x_2,y_2)\longrightarrow A(0,0),B(1,-1)[/tex]
Using their coordinates we are able to calculate slope.
[tex]a=\dfrac{\Delta{y}}{\Delta{x}}=\dfrac{y_2-y_1}{x_2-x_1}=\dfrac{-1-0}{1-0}=-1[/tex]
Hence,
[tex]y=-1\cdot x+b[/tex]
The x and y terms can be replaced with coordinates of one point either A or B. I'll pick A.
[tex]0=-1\cdot0+b[/tex]
And now solve for b.
[tex]0=0+b\Longrightarrow b=0[/tex]
Hence,
[tex]y=-1\cdot x+0[/tex]
Simply,
[tex]\boxed{y=-x}[/tex]
Hope this helps.
r3t40