本地留着太麻烦就写题解留在云端哈,本人很菜有借鉴其他人的答案 摘要:解题思路:注意事项:此解法并不能100分,只能89分,原因不太清楚可能是值域的问题,希望有大佬指出问题参考代码:参考代码:#include<stdio.h>intarr…… 题解列表 2025年10月11日 0 点赞 0 评论 8 浏览 评分:0.0
通俗易懂解法 摘要:解题思路:这里要注意到500,其实一共有501棵树,总数等于a+1(L+1)参考代码:#include<iostream>#include<algorithm>…… 题解列表 2025年10月08日 1 点赞 0 评论 27 浏览 评分:0.0
C++选择排序从小到大 摘要:#include<iostream>using namespace std;int main(){ int arr[10]; int min…… 题解列表 2025年10月06日 0 点赞 0 评论 56 浏览 评分:0.0
[STL训练]周瑜的反间计:利用vector<vector<int>>存储数据,之后利用二分法查询,结构清晰 摘要:1、解题思路:利用vector<vector<int>>存储数据,之后利用二分法查询,打印输出。2、注意事项:注意每个case后有一个空行。3、参考代码:#include<…… 题解列表 2025年10月06日 2 点赞 0 评论 74 浏览 评分:10.0
优先队列实现看病,取消同步流避免超时 摘要:解题思路:优先队列,实现看病案例注意事项:取消同步流,避免超时参考代码://看病 取消同步流,加快速度#include <bits/stdc++.h>using namespace std…… 题解列表 2025年10月04日 0 点赞 0 评论 85 浏览 评分:4.0
哥德巴赫曾猜测思路简单解 摘要:解题思路:注意事项:参考代码:#include<iostream>#define MAX 32767using namespace std;bool isPrime(int num){&n…… 题解列表 2025年09月29日 0 点赞 0 评论 193 浏览 评分:7.0
优雅的代码往往只需要一个简单的偏移量就能搞定! 摘要: #include #include #include #include using namespace std; const int dx[] = {-2,-2,2,2,1,-1…… 题解列表 2025年09月29日 1 点赞 0 评论 178 浏览 评分:10.0
编写题解 3106: 最优乘车(travel) 摘要:C++代码:```cpp#include #include #include #include using namespace std;const int INF=0x3f…… 题解列表 2025年09月27日 1 点赞 0 评论 173 浏览 评分:0.0
2798: 整数序列的元素最大跨度值 摘要:#include <bits/stdc++.h>using namespace std;int main(){ int n,maxx= -1e18 ,minn=1…… 题解列表 2025年09月24日 0 点赞 0 评论 304 浏览 评分:0.0
2799: 奥运奖牌计数 摘要:#include <bits/stdc++.h>using namespace std;int main(){ int n; int a…… 题解列表 2025年09月24日 0 点赞 0 评论 286 浏览 评分:0.0