Back to Practice
#0046
Circular Seating Neighbor Rule
MediumAptitude15 min15 XP
Problem
A, B, C, and D sit around a circular table facing the center. B sits to the immediate right of A. C sits opposite A. Who sits to the immediate left of A?
Why This Matters
Seating puzzles feel scary until you anchor one person and apply constraints one at a time.
Examples
Example 1
InputB right of A; C opposite A; four people facing center
OutputD
Fix A. B goes to A's right, C goes opposite A, so D fills the remaining seat to A's left.
Constraints
- Everyone faces the center.
- In circular arrangements, you may fix one person to remove rotational duplicates.
CodeReasoning
A, B, C, and D sit around a circular table facing the center. B sits to the immediate right of A. C sits opposite A. Who sits to the immediate left of A?
Visible browser tests run here when available.
Testcases1 visible / 3 hidden categories
Four-person circle
InputB right of A, C opposite A
ExpectedD
Only one seat remains for D, and it is left of A.
Hidden Test Categories
Facing outward reverses left/rightFive or more peopleMultiple possible arrangements