随笔分类 -  笔记,作业,代码,记录 / 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 阅读全文
posted @ 2023-08-23 12:05 HelloHeBin 阅读(222) 评论(0) 推荐(0)
摘要:## 上午简单排序 - [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 阅读全文
posted @ 2023-08-22 11:57 HelloHeBin 阅读(104) 评论(0) 推荐(0)
摘要:## 上午 - [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, 阅读全文
posted @ 2023-08-21 14:16 HelloHeBin 阅读(162) 评论(0) 推荐(0)
摘要:## 上午递归,文件 - [B2064 斐波那契数列](https://www.luogu.com.cn/problem/B2064) - [P1255 数楼梯](https://www.luogu.com.cn/problem/P1255) 点击查看代码 ``` #include using na 阅读全文
posted @ 2023-08-18 13:51 HelloHeBin 阅读(169) 评论(0) 推荐(0)
摘要:## 上午二维数组/函数 - [B2101 计算矩阵边缘元素之和](https://www.luogu.com.cn/problem/B2101) 分析:尽量对每个元素只遍历一次,如果发现是边缘元素,那么加入即可。 点击查看代码 ``` #include using namespace std; c 阅读全文
posted @ 2023-08-17 12:50 HelloHeBin 阅读(190) 评论(0) 推荐(0)
摘要:## 上午/一维数组排序 - [P5723 【深基4.例13】质数口袋](https://www.luogu.com.cn/problem/P5723) 点击查看代码 ``` #include using namespace std; int main() { int l,s=0, p=0; cin 阅读全文
posted @ 2023-08-16 13:20 HelloHeBin 阅读(186) 评论(0) 推荐(0)
摘要:## 上午测试讲题 - [U259234 累加累乘/accmul](https://www.luogu.com.cn/problem/U259234) 分析:直接开两个变量记录答案即可,使用for循环n次,对于s1也可以使用等差数列求和公式。 点击查看代码 ```cpp #include using 阅读全文
posted @ 2023-08-15 13:49 HelloHeBin 阅读(163) 评论(0) 推荐(0)