Groups
Category
A segment tree with lazy propagation can support range updates of the form x โ aยทx + b (affine transformations) and range-sum queries in O(log n) per operation.
Top trees are dynamic tree data structures that represent a forest as a hierarchy of clusters, allowing O(log n) amortized time for link, cut, path queries/updates, and many subtree queries.