Given YA = B, you can solve for Y by multiplying by A ⁻¹ on the right (on both sides of the equation). So we have
YA = B ==> (YA) A ⁻¹ = BA ⁻¹ ==> Y (AA ⁻¹) = BA ⁻¹ ==> Y = BA ⁻¹
provided that the inverse of A exists. In this case, det(A) = 5 ≠ 0, so the inverse does exist, and
![A=\begin{bmatrix}-1&-4\\0&-5\end{bmatrix} \implies A^(-1)=\frac1{\det(A)}\begin{bmatrix}-5&0\\4&-1\end{bmatrix} = \begin{bmatrix}-1&0\\\frac45&-\frac15\end{bmatrix}](https://img.qammunity.org/2022/formulas/mathematics/college/sjhuot8tm26ypz15jlwyfrnpjvzomonkkh.png)
Then
![Y=\begin{bmatrix}5&-5\\8&-8\end{bmatrix}A^(-1) = \begin{bmatrix}-5&5\\-8&\frac{24}5\end{bmatrix}](https://img.qammunity.org/2022/formulas/mathematics/college/k7mi8g2f7p257dh5g19ez52evw5pica9f3.png)