Matrix : Not as complex as movie There are three standards questions which are asked regularly in technical interview which do not involve any algorithm as such. Just working around with matrix indices will suffice for solving these problems. Problem statement 1. Given a N x M matrix, print all elements in it in spiral order. 2. Given a N x N matrix, rotate the given matrix by 90 degree. 3. Given a N x M matrix, replace a row and column with 1 if any position in that row or column has 1. Problem 1: Given a N x M matrix, print all elements in it in spiral order.
Read full article from Algorithms and Me: Matrix : Not as complex as movie