蓝桥杯2013年第四届真题-核桃的数量-题解(C++代码) 这个题实际上就是求三个数的最小公倍数的,那么就先求两个数的最小公倍数,再把求得出的结果与第三个数再次求最小公倍数,然后输出此次结果即可```cpp#includeusingnamespacestd;intchu_bei(intx,inty){inta=0, 题解列表 2019年08月27日 0 点赞 0 评论 1246 浏览 评分:0.0
递归搜索解法 每次从最后一位开始搜索,如果当前位置已经到达这个位置的最大值,就递归进行下一位的搜索,如果当前没有到达最大值,就把当前位置进行+1操作,如果到第一位时还不能加,就证明是错误的。```cpp#include#include#include#include#includeusingnamespacestd 题解列表 2019年08月25日 0 点赞 0 评论 1751 浏览 评分:9.9
递归搜索解法 每次从最后一位开始搜索,如果当前位置已经到达这个位置的最大值,就递归进行下一位的搜索,如果当前没有到达最大值,就把当前位置进行+1操作,如果到第一位时还不能加,就证明是错误的。```cpp#include#include#include#include#includeusingnamespacestd 题解列表 2019年08月25日 0 点赞 0 评论 1706 浏览 评分:9.9
蓝桥杯历届试题-小朋友排队 (C++代码)树状数组O(nlogm)算法 ```cpp双倍经验:https://www.lintcode.com/problem/count-of-smaller-number-before-itself/description?_from=ladder&&fromId=26建议先把这道题做完之后再来做此题;思路:相信看到题目的你第一时间想到 题解列表 2019年08月25日 0 点赞 2 评论 2861 浏览 评分:9.9
蓝桥杯历届试题-小朋友排队 (C++代码)线段树O(nlogm)算法 ```cpp双倍经验:https://www.lintcode.com/problem/count-of-smaller-number-before-itself/description?_from=ladder&&fromId=26建议先把上题做完之后再来做此题;思路:相信看到题目的你第一时间想到的 题解列表 2019年08月24日 0 点赞 0 评论 1853 浏览 评分:9.5
优质题解 蓝桥杯2015年第六届真题-广场舞-题解(C++代码) 摘要:#### 原题链接:[问题 1838: [蓝桥杯][2015年第六届真题]广场舞](https://www.dotcpp.com/oj/problem1838.html "问题 1838: [蓝桥杯]…… 题解列表 2019年08月24日 1 点赞 5 评论 2312 浏览 评分:9.1
蓝桥杯2017年第八届真题-k倍区间 (C++代码)前缀和O(n)算法 ```求区间和,可以通过前缀和来得到各个区间的和。A[i]表示第1个元素到第i个元素的和。那么A[r]-A[l-1]就是区间[l,r]的和。区间[l,r]的和如果是k的倍数,那么(A[r]-A[l-1])%k==0即A[r]%k==A[l-1]%k那么可以求出每个前缀和, 题解列表 2019年08月24日 0 点赞 0 评论 1945 浏览 评分:6.0
并查集思想 ```cpp#include#include#include#includeusingnamespacestd;typedeflonglongLL;namespaceIO{inlineLLread(){LLo=0,f=1;charc=getchar();while(c>'9'||c='0'&&c 题解列表 2019年08月24日 0 点赞 0 评论 1813 浏览 评分:9.9
优质题解 erase()函数解决!!!2024题-17.链表删除练习-题解(C++代码)加油吧!同路人! //erase函数在调用之后迭代器会变成野指针,不能直接++或者--关于erase函数的详细见:https://blog.csdn.net/wangshubo1989/article/details/5 题解列表 2019年08月24日 0 点赞 3 评论 1843 浏览 评分:9.9
dp动态规划解法 一个区间的能量=左边的珠子*右边的珠子*右边下一个珠子合并两个区间的能量=左边区间的能量+右边区间的能量+左区间的左珠子*右区间的左珠子*右区间的下一个珠子。```cpp#include#include#includeusingnamespacestd;typedeflonglongLL;namesp 题解列表 2019年08月24日 0 点赞 1 评论 1514 浏览 评分:9.9