摘要:
 阅读全文
posted @ 2023-04-12 18:05
Tshaxz
阅读(16)
评论(0)
推荐(0)
摘要:
占坑 阅读全文
posted @ 2023-04-12 18:02
Tshaxz
阅读(22)
评论(0)
推荐(0)
摘要:
占坑 阅读全文
posted @ 2023-04-12 18:00
Tshaxz
阅读(13)
评论(0)
推荐(0)
摘要:
占坑 阅读全文
posted @ 2023-04-12 17:59
Tshaxz
阅读(13)
评论(0)
推荐(0)
摘要:
占坑 阅读全文
posted @ 2023-04-12 17:54
Tshaxz
阅读(18)
评论(0)
推荐(0)
摘要:
注:弗洛伊德算法也可以在数据范围很小时($10^2$级别)求单源最短路,例如3488.最短路径。优点是弗洛伊德算法相对于Dijkstra更好写,就三个for循环,代码比较短,缺点是只有在数据范围是$10^2$级别才能用。 3488. 最短路径 #include <iostream> #include 阅读全文
posted @ 2023-04-12 17:40
Tshaxz
阅读(27)
评论(0)
推荐(0)
摘要:
超级(虚拟)源点类型 1488. 最短距离(超级源点) 建立超级源点,从超级源点向某些点连一条权值为0的单向边 #include <iostream> #include <algorithm> #include <cstring> #include <queue> using namespace s 阅读全文
posted @ 2023-04-12 17:33
Tshaxz
阅读(23)
评论(0)
推荐(0)
摘要:
207. 课程表 const int N = 100010, M = 5010; class Solution { public: int h[N], e[M], ne[M], idx = 0; int in[N], q[N]; void add(int a, int b) { e[idx] = b 阅读全文
posted @ 2023-04-12 17:04
Tshaxz
阅读(23)
评论(0)
推荐(0)

浙公网安备 33010602011771号