Amazon Interview Question

3rd round : One coding questions was asked. In interview room , n seats are given . All are initially empty . People are coming . I need to allocate seats . And they want to seat as far away to each other as possible. This I solved using queue. Then modification in this question. Some people are already seated. Then I have to allocate seats .