← Morgan Stanley questions
CodingMediumReported in a candidate post, Feb 2024

Asteroid collision problem using stack

Filed under Morgan Stanley

We are given an array of integers asteroids representing asteroids in a row. For each asteroid, the absolute value represents its size, and the sign represents its direction (positive meaning right…

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 Morgan Stanley questions

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