摘要: 题意 给定一张图,走出当前边的时间为 \(i\)。 \(q\) 次询问,问 \(s\) 是否能在 \(l \to r\) 中走到 \(t\)。 Sol 考虑将边从大到小插入图中。 注意到当前边只能对起点造成贡献。 复杂度 \(O(n \times \max\{n, m\})\) Code #incl 阅读全文
posted @ 2023-11-24 17:15 cxqghzj 阅读(2) 评论(0) 推荐(0) 编辑