HDU-1166-敌兵布阵(线段树模板题)

博主个人博客 题目链接 题意: 给n个兵营及每个兵营的初始人数,然后选择4种操作中的一个,一个经典的线段树模板题 题解: 直接套线段树模板就可以了 代码: #include<stdio.h> #include<bits/stdc++.h> using namespace std; int n,p,a,b,m,x,y,ans; struct node { int l,r,w,f; }tree
相关文章
相关标签/搜索