摘要: 首先有一个经典小结论:\(k > 1\) 时,区间 LCA 的深度为 \(\min\limits_{i = l}^{r-1} \text{dep}_{\operatorname{LCA}(i, i+1)}\). 考虑对每个 \(x = \text{dep}_{\operatorname{LCA}(i 阅读全文
posted @ 2025-06-05 21:45 心灵震荡 阅读(40) 评论(0) 推荐(0)