Q:

Find the value of lambda for which the system of equations can be solved? 

I'm having some trouble with a problem here.  I have the following system of equations:
$$
        \begin{bmatrix}
        1 & 1 & 2 \\
        1 & 2 & 1 \\
        2 & 1 & 5 \\
        \end{bmatrix}
        \begin{bmatrix}
        x \\
        y \\
        z \\
        \end{bmatrix}
=
        \begin{bmatrix}
        3 \\
        4 \\
        \lambda \\
        \end{bmatrix}
$$
I need to find the value of $\lambda$ that allows the system to be solved.  I can't just premultiply the inverse of the 3x3 matrix over, since it's singular, so I multiplied it out to get:
$$
x+y+2z=3
$$$$
x+2y+z=4
$$$$
2x+y+5z=\lambda
$$
I understand that if $\lambda=5$, then the third equation is not independent of the other two.  I could just set $\lambda$ to anything but $5$, but that doesn't sound like what I'm supposed to do, and plus, the problem says "the value of $\lambda$," not "a value of $\lambda$."
Am I confused here, or does this not make sense? 
Thanks. 
-Zane

A:

For an ad hoc solution, you may note that
$$
3 (x+y+2z) - (x+2y+z) = 2x+y+5z,
$$
so if the system has a solution... (spoiler)

 you must have $5 = 3 \cdot 3 - 4 = \lambda$.

For a more conceptual approach, do Gaussian elimination on
$$
\begin{bmatrix}
        1 & 1 & 2 & 3\\
        1 & 2 & 1 & 4\\
        2 & 1 & 5 & \lambda\\
        \end{bmatrix}
$$
to get
$$
\begin{bmatrix}
        1 & 1 & 2 & 3\\
        0 & 1 & -1 & 1\\
        0 & 0 & 0 & \lambda - 5\\
        \end{bmatrix}
$$
which also yields that for the system to have a solution, you need $\lambda - 5 = 0$.

