Your Dashboard
Interview Coaching
Learn
System Design
ML System Design
Code
Behavioral
Salary Negotiation
Interview Guides
Search
⌘K
Get Premium
Leetcode 1325. Delete Leaves With a Given Value
Given a binary tree and a target value, repeatedly remove all leaf nodes whose value equals the target; removals may create new leaves that also equal the target, so you must prune until no such leaves remain. This is typically solved with a post-order (bottom-up) traversal to decide whether to delete each node.
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.