摘要:
1. 单源最短路 1.1 所有边权值非负 1.1.1 朴素Dijkstra 时间复杂度 $ O(n^{2}) $ Code #include<bits/stdc++.h> using namespace std; 1.1.2 堆优化Dijkstra 时间复杂度 $O(m\log n)$ 1.2 存在 阅读全文
posted @ 2024-04-23 11:55
Wiz_HUA
阅读(15)
评论(0)
推荐(0)
摘要:
1. 裸板子 题目链接:P3379 【模板】最近公共祖先(LCA) 展开代码 #include<bits/stdc++.h> using namespace std; #define P(x) cout<<#x<<":"<<x<<endl; #define pb push_back const in 阅读全文
posted @ 2024-04-23 11:54
Wiz_HUA
阅读(15)
评论(0)
推荐(0)

浙公网安备 33010602011771号