随笔分类 - 笔记,作业,代码,记录 / 2023.8.15集训笔记
摘要:## 数据结构 - [P1102 A-B 数对](https://www.luogu.com.cn/problem/P1102) 点击查看代码 ``` #include using namespace std; const int N=2e5+10; int n,m,c,a[N],st[N],ans
阅读全文
摘要:## 上午简单排序 - [P5143 攀爬者](https://www.luogu.com.cn/problem/P5143) 点击查看代码 ``` #include using namespace std; const int N=5e4+10; struct T{ int x,y,z; }a[N
阅读全文
摘要:## 上午 - [P1789 【Mc生存】插火把](https://www.luogu.com.cn/problem/P1789) 点击查看代码 ``` #include using namespace std; const int N=110; bool a[N][N]; int n,m,k,x,
阅读全文
摘要:## 上午递归,文件 - [B2064 斐波那契数列](https://www.luogu.com.cn/problem/B2064) - [P1255 数楼梯](https://www.luogu.com.cn/problem/P1255) 点击查看代码 ``` #include using na
阅读全文
摘要:## 上午二维数组/函数 - [B2101 计算矩阵边缘元素之和](https://www.luogu.com.cn/problem/B2101) 分析:尽量对每个元素只遍历一次,如果发现是边缘元素,那么加入即可。 点击查看代码 ``` #include using namespace std; c
阅读全文
摘要:## 上午/一维数组排序 - [P5723 【深基4.例13】质数口袋](https://www.luogu.com.cn/problem/P5723) 点击查看代码 ``` #include using namespace std; int main() { int l,s=0, p=0; cin
阅读全文
摘要:## 上午测试讲题 - [U259234 累加累乘/accmul](https://www.luogu.com.cn/problem/U259234) 分析:直接开两个变量记录答案即可,使用for循环n次,对于s1也可以使用等差数列求和公式。 点击查看代码 ```cpp #include using
阅读全文

浙公网安备 33010602011771号