自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(3)
  • 收藏
  • 关注

原创 专题四 · 1003

代码及解释#include <algorithm> #include <cmath> #include <cstdio> #include <iostream>// 上课讲的一道题 // 并查集的思考: // 一种并查集是上课的时候老师讲的 // 这种并查集的查询效率很快 // 但是更新的速度比较慢 // 实际上另外一种是查询效率慢 // 更新速度很快 // 这两种可以应用于不同的场景using s

2016-06-29 17:17:35 249

原创 专题四 · 1002

代码及解释#include <algorithm> #include <cmath> #include <cstdio> #include <iostream>// kruskal 求最小生成树,用到并查集struct Node { int x, y; double cost; } g[5005];int pre[105];int find(int n) { return n == pre[

2016-06-28 10:21:57 251

原创 专题四 · 1001

代码及解释#include <algorithm> #include <iostream>// // kruskal + 并查集 + 边表 //struct node { int from; int to; int w; };node edge[102 * 100]; int parent[102];bool cmp(node a, node b) { if (a.w <= b.w)

2016-06-13 20:45:17 265

空空如也

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除