Pregunta de entrevista de Microsoft

The interview was mostly on algorithms and problem solving. Had to write code on the white board while solving the problem.