题解列表
会find就很好做了
摘要:
```cpp
#include
using namespace std;
#define endl '\n'
const int N=105;
string s;
int……
信息学奥赛一本通T1273-货币系统
摘要:解题思路:完全背包注意事项:参考代码:#include<iostream>
using namespace std;
const int N = 1e2 + 10;
int a[N],f[N];……
[递归]母牛的故事(动态规划,递归)
摘要:解题思路:写出数学表达式 F(x){ x<=3 f(x)=x;// 前三年只有一头母牛生孩子 &nbs
1099: 校门外的树
摘要:解题思路:注意事项:参考代码:#include <bits/stdc++.h>typedef long long ll;const int N=1e7;using namespace std;int ……
1738-排序(由小到大*多数据排序)
摘要:解题思路:用数组储存数据,两个for循环遍历数据,比较大小交换位置注意事项:会用到new获取数组大小参考代码:#include <iostream>using namespace std;void s……
2136: 信息学奥赛一本通T1272-分组背包
摘要:解题思路:分组背包注意事项:参考代码:#include<iostream>
#include<algorithm>
using namespace std;
const int N = 40;……
2135: 信息学奥赛一本通 T1271-潜水员
摘要:解题思路: 01 背包,f[i][j] 表示i氧j氮气瓶所需要的最小重量,(W) 重量维度优化省略, 因此以倒序遍历i,j 注意事项:当i - x 为负数时注意越界,因此取max(0,i-x)参考代码……