finding the distance between a vector and image

I have a vector b

[1

1

1

0]

and a matrix A

[1 0 1

2 -1 1

-1 2 1

0 -1 -1]

it says

1. the sum of the first two columns is equal to the third and conclude that the rank(A) = 2

2. replace A by a matrix B with maximal rank and same image

3. compute the peojection P on Im(A) = Im(B) by u sing the method of least square solution

4. compute the projection b0 = Pb of b on Im(A)

5. compute the distance between b and b0

I get the first two steps but I don't understand how to do the 3rd. I'm pretty sure I can do the last two steps once i get the result from step 3. can anyone clarify on what I'm supposed to do in step 3?