Need help with this question please! 2 other tutors haven’t been able to help me

To obtain the rule that defines the function given, we will follow the steps below:
For the first function
Step 1:
Obtain the coordinates of the line on the left-hand side of the graph
The coordinates are: (-1,4) and (-2,3)
Step 2: Get the equation of the line
[tex]\frac{y-4}{x+1}=\frac{3-4}{-2+1}[/tex]=>
[tex]\begin{gathered} \frac{y-4}{x+1}=\frac{-1}{-1} \\ \\ \frac{y-4}{x+1}=1 \\ \\ y-4=x+1 \\ y=x+5 \end{gathered}[/tex]Hence the equation of the line given is
[tex]y=x+5\text{ for the range x}\leq-1[/tex]Step 3: Get the equation of the second line on the graph
[tex]y=2[/tex]Hence, the equation of the line is
[tex]y=2\text{ for the range x>1}[/tex]Therefore, the rule that defines the function is:
[tex]f(x)=\begin{cases}x+5\text{ for x}\leq-1 \\ -2\text{ for x>1}\end{cases}[/tex]