InterviewDB Question

Student Seating - Assign Seats Maximizing Distance from Existing Students

Question Details

Problem A row of n seats is represented as a binary array where 1 = occupied, 0 = empty. A new student wants to sit as far as possible from the nearest occupied seat. Return the maximum distance achievable and the index of the optimal seat. If multip…

Full Details

🔒

Unlock full leaked content

Full insider details, leaked discussions, and candidate experiences.

Get Premium →

Topics

Coding Onsite Phone