New
ML System Design & SQL tracks just landed
See what's new
×
Question Bank
Pricing
Blog
Forum
HOT
JobRadar
NEW
Referral
Description
Solution
Discussion
Submissions
Ask AI
Question Bank
Hudson River Trading
Coding Question
AI Insights
Quick Summary
Simulate placing a piece on an n x n Reversi board at a specified coordinate.
Identify and flip opponent pieces in all 8 directions if they form a valid bounded sequence.
Return the updated board or the original if the move is invalid or flips no pieces.
What This Tests
Grid traversal and boundary validation
Multi-directional scanning logic
State mutation and conditional flipping
Index arithmetic for diagonal movement
Common Patterns
DFS/BFS
Graph Traversal
Collapse
Hint 1
Hint 2
What Interviewers May Ask Next
Accepted
548
/1.3k
Acceptance Rate
43.8%
Ask AI Assistant
Ask AI Assistant
Ask me anything about this coding question!
Qwen
Qwen3.6-Flash
0/2000
Auto
Debug
Run
Submit
Test Cases
Input
board =
row =
col =
player =
Output
Expected