题解列表
2134混合背包 简单动态规划(简单易理解版)
摘要:解题思路:就是01背包,多重背包,和无限背包合起来,加个判断条件就好了注意事项: 1.这里使用普通的dp数组,方便初学者理解. 加上这道题普通的dp数组也可以过,就不再优化了 ……
求和训练(python)
摘要:解题思路:注意事项:参考代码:a,b,c=map(int,input().strip().split())e,r,t=0,0,0for i in range(1,a+1): e+=i for……
2822: 求分数序列和
摘要:```cpp
#include
#include
using namespace std;
int main()
{
int n;
double a=1.0,b=2.0,……
2918: 成绩排序
摘要:```cpp
#include
#include
using namespace std;
typedef struct student
{
char m[20];
in……
2920: 分数线划定
摘要:```cpp
#include
#include
using namespace std;
typedef struct student
{
int id;
int ma……
2784: 收集瓶盖赢大奖
摘要:```cpp
#include
using namespace std;
int main()
{
int a,b;
cin>>a>>b;
if(a>=10||b……
2785: 判断一个数能否同时被3和5整除
摘要:```cpp
#include
using namespace std;
int main()
{
int n;
cin>>n;
if(n%15==0)
……
2786: 判断能否被3、5、7整除
摘要:```cpp
#include
using namespace std;
int main()
{
int count=0,a;
cin>>a;
for(int ……
2787: 有一门课不及格的学生
摘要:```cpp
#include
using namespace std;
int main()
{
int a,b;
cin>>a>>b;
if(a>=60&&b……