The Old New Thing

Tales from the interview: Can you rotate this two-dimensional array?

My colleague jeffdav told me about one job interview with a graduating college senior that didn't go well because the candidate simply gave up. He offered a simple programming task: Write a function that takes a 4×4 two-dimensional array and rotates it clockwise by 90 degrees. For example, the entry in the upper left corner of ...