题解列表

筛选

C++老管家的忠诚(线段树做法)

摘要:区间查询,果断想到线段树,看了一下题解有很多用的st表,但感觉st表模板太难记了,线段树相对好记很多,还是线段树更香一点。树状数组也可以求最值但得改模板。参考代码:#include using nam……

过滤多余的空格

摘要:解题思路:注意事项:参考代码:#include<bits/stdc++.h>using namespace std;int main(){ string s; getline(cin,s); stri……

台球碰撞问题

摘要:解题思路:注意事项:参考代码:#include<iostream>using namespace std;#include<math.h>//调用数学库函数//使用三角函数注意事项://1、包含头文件……