← Uber questions
CodingEasyReported in a candidate post, Jul 2025

Delete an edge to minimize subtree sum difference

Filed under Uber

You are given a tree with n nodes, where node i has a non-negative value values[i], and the n-1 edges of the tree. You must remove exactly one edge, which splits the tree into two subtrees. Return the…

You've read your 3 free write-ups

Sign up free to keep reading. Your account opens the first 10 questions of every company.

Related Uber questions

Collected from public candidate posts and coding forums. Updated Nov 2026.