ICode9

精准搜索请尝试: 精确搜索
  • POJ3237 Tree (树链剖分)2022-07-01 20:34:52

    通过打懒标记实现区间取反,和线段树基本操作都差不多。 本题还是一道边权化为点权的问题。 200行巨长代码: 1 #include<cstdio> 2 #include<cstring> 3 #include<algorithm> 4 using namespace std; 5 const int maxn=10010; 6 int head[maxn],cnt=0,total=0;//头结点

专注分享技术,共同学习,共同进步。侵权联系[81616952@qq.com]

Copyright (C)ICode9.com, All Rights Reserved.

ICode9版权所有