Your Dashboard
Interview Coaching
Learn
System Design
ML System Design
Code
Behavioral
Salary Negotiation
Interview Guides
Search
⌘K
Get Premium
Leetcode 3585. Find Weighted Median Node in Tree
Given a weighted tree and many queries (u, v), find the first node along the path from u to v where the cumulative edge weight from u reaches at least half the total path weight; this requires fast path-weight prefix queries using preprocessing (distances + LCA) and jump operations (e.g., binary lifting or HLD) to locate the median node efficiently.
Question Timeline
See when this question was last asked and where, including any notes left by other candidates.
All Regions
Comments
Hello Interview Premium
Your account is free and you can post anonymously if you choose.