How do you usually implement HLD with segment tree?
Heavy-Light Decomposition with segment tree.
Do you flatten the tree by DFS (prioritizing the heavy child) and use a single segment tree over the whole array,
or build a separate segment tree for each chain?