← Amazon questions

Traffic car parking slot rearrangement

Filed under Amazon

Given n cars in n+1 parking slots, find the minimum number of swaps to reach a target configuration, using the single empty slot as a buffer.

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 Amazon questions

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