New
ML System Design & SQL tracks just landed
See what's new
×
Question Bank
Pricing
Blog
Forum
HOT
Referral
Description
Solution
Discussion
Submissions
Ask AI
Question Bank
Pinterest
Coding Question
AI Insights
Quick Summary
Manage hierarchical permissions where granting or revoking affects a region and all its descendants.
Track chronological operations per advertiser to resolve overlapping grants and revokes.
Query access status by traversing from a target region up to the hierarchy root.
What This Tests
Tree construction and parent-child relationship mapping
State tracking with timestamps or versioning
Path-based querying in hierarchical structures
Handling invalid inputs and edge cases gracefully
Common Patterns
Graph Traversal
Hashing
DFS/BFS
Collapse
Hint 1
Hint 2
Hint 3
What Interviewers May Ask Next
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
Output
Expected