Amazon interview question

reverse a spiral matrix in binary