Amazon Interview Question

Given a matrix, write a function to rotate it 90 degrees clockwise.