M={{2,1,3,1,0,-1},{1,-1,2,0,2,1},{7,-2,11,3,8,-5}};
RowReduce[M]//MatrixForm
MatrixRank[M]