Added a solution to rotate matrix in place.