← Goldman Sachs questions

Rotate matrix 90 degrees anti-clockwise

Filed under Goldman Sachs

You are given an n x n 2D matrix representing an image. Rotate the image 90 degrees anti-clockwise in-place.

You've read your 3 free write-ups

Sign up free to keep reading. Your account opens the first 10 questions of every company.

Related Goldman Sachs questions

Collected from public candidate posts and coding forums. Updated Nov 2026.