题解列表
信息学奥赛一本通T1291-数字组合
摘要:解题思路:01 背包, f[j] 表示和为j的方案数, 当j = 0 时, 方案为一个数字都不选,此时方案数为1注意事项:参考代码:#include<iostream>
#include<algor……
极简-c++语言初学者思路*通俗易懂
摘要:#include <iostream>
using namespace std;
int main()
{
int n;
cin >> n;
for (int i = 6; i <=……
自定义函数之数字后移
摘要:解题思路:用取余来求出对应的下标注意事项:注意用另外一个数组d存储数据参考代码:#include<stdio.h>int main(){ int a,b; int index; ch……
3056: 宠物小精灵之收服
摘要:解题思路:01背包 两个限制条件, 双重循环倒序遍历 f[i][j]表示i个精灵球j伤害值最多收获的精灵注意事项:得到大值,再找最小的j参考代码:#include<iostream>
#includ……
Python利用贡献度法求解
摘要:#### 思路借鉴
利用贡献度法,参考链接https://juejin.cn/post/7350185416652275712
##### 草稿思路
| left | right | lef……
1013: [编程入门]Sn的公式求和
摘要:解题思路:注意事项:参考代码:n = int(input())
s = 0
for i in range(1, n + 1):
temp = '2' * i
s……
hello world C语言代码
摘要:解题思路:注意事项:1.注意输出上下的*一个都不能少。2.记得前两行有换行符号。3.注意hello和world开头大写参考代码:#include<stdio.h>int main(){ prin……