上一页 1 ··· 5 6 7 8 9 10 11 12 13 ··· 54 下一页
  2023年10月5日
摘要: 带权并查集板题 维护到根的距离 #include <iostream> #include <algorithm> #include <cstring> #include <vector> #include <queue> using namespace std; const int N =2e5+1 阅读全文
posted @ 2023-10-05 21:29 towboat 阅读(7) 评论(0) 推荐(0) 编辑
  2023年10月4日
摘要: 01bfs 跑完d1 ,d2 ( 单源最短路 枚举 中间点(去掉的点 #include <iostream> #include <algorithm> #include <vector> #include <queue> #include <map> using namespace std; con 阅读全文
posted @ 2023-10-04 20:39 towboat 阅读(4) 评论(0) 推荐(0) 编辑
  2023年10月3日
摘要: maintain block size: fa[fy]=fx; sz[fx]+=sz[fy],sz[fy]=0; 阅读全文
posted @ 2023-10-03 15:26 towboat 阅读(2) 评论(0) 推荐(0) 编辑
  2023年10月2日
摘要: :边权存储在dep较大的点,转化为点权问题 注意区间查询时,如果当前x,y在一条重链上时的情况 https://www.luogu.com.cn/problem/P1967 https://www.luogu.com.cn/problem/AT_abc294_g https://darkbzoj.c 阅读全文
posted @ 2023-10-02 18:32 towboat 阅读(7) 评论(0) 推荐(0) 编辑
  2023年9月25日
摘要: 点双 找到割点后 一直退栈 http://ybt.ssoier.cn:8088/problem_show.php?pid=1521 include <iostream> #include <algorithm> #include <cmath> #include <vector> #include< 阅读全文
posted @ 2023-09-25 22:13 towboat 阅读(4) 评论(0) 推荐(0) 编辑
  2023年9月24日
摘要: for( x: iter ) x为一个pair map<int,int> mp ; signed main(){ mp[3] =4 ; mp[33] =1; for(auto xx:mp) cout << xx.first<<' '<<xx.second <<endl; } 阅读全文
posted @ 2023-09-24 21:15 towboat 阅读(4) 评论(0) 推荐(0) 编辑
  2023年8月28日
摘要: https://vjudge.net/article/2790 然后要启用开发者模式,然后就可以打开开发者工具。 (Safari–Preferences呼出首选项面板(或用快捷键 command+, 直接呼出)。 在 Advanced 菜单面板下,勾选 Show Develop Menu in me 阅读全文
posted @ 2023-08-28 18:46 towboat 阅读(40) 评论(0) 推荐(0) 编辑
  2023年8月21日
摘要: 来源于 https://vjudge.net/problem/CodeForces-291E void init(int x,int fa){ val[x]=val[fa]*S+(ul)c[x]; f[x][0]= fa; for (int i=1;i<20;++i) f[x][i]=f[f[x][ 阅读全文
posted @ 2023-08-21 14:34 towboat 阅读(8) 评论(0) 推荐(0) 编辑
  2023年7月22日
摘要: 。每个人都有一个考试等级,教室里面一共有N个课桌,按照顺序排成一列,每个课桌可以坐两个人,记他们的能力等级为(A[i],B[i])。 现在决定对能力等级为K的人进行测验。从这N排中选择连续的L排进行测验,要求这L排中的每一排至少有一个人考试等级为K。 现在想知道L的最大值以及对应的等级K。 #inc 阅读全文
posted @ 2023-07-22 12:52 towboat 阅读(10) 评论(0) 推荐(0) 编辑
摘要: #include<iostream> #include<cstdio> #include<cstring> #include<algorithm> using namespace std; struct hp{ int ai,bi,ci; }a[1005]; bool cmp(hp a,hp b){ 阅读全文
posted @ 2023-07-22 11:29 towboat 阅读(10) 评论(0) 推荐(0) 编辑
上一页 1 ··· 5 6 7 8 9 10 11 12 13 ··· 54 下一页
点击右上角即可分享
微信分享提示