Okay so I was solving some questions on vectors but then I came across a question which I could not solve quickly enough . The method I used is basically super lengthy and prone to errors . I had to find the values of $\lambda$ and $\mu$ using the two relations (comparing them).
Basically I found the coordinates of the same point once in terms of $\lambda$ and then in terms of $\mu$ .
$$\left (\frac{16\lambda + 6}{\lambda +1}\right),\left (\frac{-19\lambda - 7}{\lambda +1}\right),\left (\frac{-4\lambda}{\lambda +1}\right) \cdots (1)$$
$$\left (\frac{2\mu}{\mu +1}\right),\left (\frac{-5\mu+3}{\mu +1}\right),\left (\frac{10\mu-6}{\mu +1}\right) \cdots (2)$$
On comparing I eventually get $\lambda=\frac{-1}{3}$ and $\mu=1$.
The thing is this takes too much time ? Is there a better way to do this ?
P.S. - I made $3$ equations and solved them and basically made more equations and solved them to get these values.
You said in the comments that the problem has originated as a question to find the intersection of two lines $AB$ and $CD$, where the co-ordinates of the points $A,B,C,D$ are given.
Solution: Express $X$ via those points as follows:
$$\vec{AX}=\alpha\vec{AB}\text{, i.e. }X=A+\alpha(B-A)$$ $$\vec{CX}=\beta\vec{CD}\text{, i.e. }X=C+\beta(D-C)$$
This gives us the vector equation:
$$\alpha(B-A)-\beta(D-C)=C-A$$
which, when written in co-ordinates, gives you a system of linear equations with unknowns $\alpha$ and $\beta$. Solving this system provides you with $\alpha$ and $\beta$, and therefore with $X$. Beware: this system may have zero, one or multiple solutions in ($\alpha, \beta$).
Example: With $A(6,-7,0)$, $B(16,-19,-4)$,$C(0,3,-6)$,$D(2,-5,10)$, the calculation goes as follows:
$$X=(6,-7,0)+\alpha((16,-19,-4)-(6,-7,0))=(6+10\alpha, -7-12\alpha, -4\alpha)$$ $$X=(0,3,-6)+\beta((2,-5,10)-(0,3,-6))=(2\beta, 3-8\beta, -6+16\beta)$$
which gives us the system:
$$\begin{array}{rcl}6+10\alpha&=&2\beta\\-7-12\alpha&=&3-8\beta\\-4\alpha&=&-6+16\beta\end{array}$$
or:
$$\begin{array}{lll} 10\alpha&-2\beta&=-6\\-12\alpha&+8\beta&=10\\-4\alpha&-16\beta&=-6\end{array}$$
Solving this gives a unique solution $\alpha=-\frac{1}{2}, \beta=\frac{1}{2}$, which then in turn gives $X=(1, -1, 2)$.