3030: 全排列 摘要:解题思路:注意事项:参考代码:#include"bits/stdc++.h" using namespace std; // 全局变量声明 int l; // 字符串长度 string s; …… 题解列表 2024年11月20日 1 点赞 0 评论 763 浏览 评分:10.0
信息学奥赛一本通T1317-组合的输出,深搜 摘要:解题思路:注意事项:参考代码:#include"bits/stdc++.h" using namespace std; // 全局变量声明 int n, r, a[100] = {1}; // …… 题解列表 2024年11月20日 0 点赞 0 评论 900 浏览 评分:0.0
糖果游戏-环状数组的左右索引公式 摘要:解题思路:初始化数组,输入循环,左右索引的循环,按照索引同时更新数组,输出的循环。注意事项:cin的位置;索引的初始化(int left);环状数组的左右索引公式-左侧:(i-1+n)%n 右侧:(i…… 题解列表 2024年11月20日 1 点赞 0 评论 663 浏览 评分:10.0
集合的划分 递归 摘要:解题思路:注意事项:参考代码:#include"bits/stdc++.h" using namespace std; long long aaa(int n, int k) { // …… 题解列表 2024年11月19日 0 点赞 0 评论 929 浏览 评分:0.0
信息学奥赛一本通T1314-过河卒 动态规划 摘要:解题思路:注意事项:参考代码:#include"bits/stdc++.h" using namespace std; // 定义全局变量,包括矩阵大小、中心点坐标和计数器 int n, m, …… 题解列表 2024年11月19日 0 点赞 0 评论 646 浏览 评分:0.0
最高的分数题解 摘要:解题思路:注意事项:参考代码:#include<iostream> #include<vector> //vector头文件 using namespace std; int max(…… 题解列表 2024年11月19日 0 点赞 0 评论 404 浏览 评分:0.0
关于 完全背包 的解题思路(C++) 其实我是以前写01背包时无意中发现完全背包的-__-#(如果不会01背包,我建议先去学习一下)。什么是完全背包?在01背包中,每件物品可以取一次,而完全背包则是物品可以取无数次(只要背包容量充足)。其中i代表物品数量,j代表物品重量。dp[i][j]表示当前背包容量为j时选择的最大价值。 题解列表 2024年11月18日 0 点赞 0 评论 679 浏览 评分:9.9
筛排处理,气死我了这题!!! 摘要:解题思路:注意事项:参考代码:#include"bits/stdc++.h" using namespace std; int main(){ // 定义变量a和数组d,其中d的大小为1…… 题解列表 2024年11月18日 0 点赞 1 评论 468 浏览 评分:9.9
应该是最简洁了的-最强小队 摘要:解题思路:题意理解错了,以为是从一段区间中选取几个结果是一整段的,几行搞定注意事项:参考代码:#include<bits/stdc++.h>using namespace std;const int …… 题解列表 2024年11月18日 1 点赞 0 评论 1051 浏览 评分:4.0
1796: 蛇形填数 摘要:解题思路:注意事项:参考代码:#include<iostream>#include<string>using namespace std;int n, a[150][150];void twins(i…… 题解列表 2024年11月18日 0 点赞 0 评论 745 浏览 评分:9.9