To find out if it has a solution, set it up in matrix form (column form) and reduce to row echelon form. So:
This is the matrix if column form with the augmented solutions. Now if you end up with some row where 0 = a number that isn't 0, there is no solution.
For the second problem:
In this case you know there is no solution since if you were to cancel out by multiplying the top row by and adding the two equations, you get:
Which we know is not true.