随笔分类 -  青少年蓝桥杯赛

摘要:一、题目来源 OJ传送门 参考题解 赛瓦维斯特定理 2017年蓝桥杯软件类省赛C++语言大学A组第8题"包子凑数",一道数论题。 2022年4月青少年蓝桥杯赛第二次省赛初级+中高级组第三题 这也太tm内卷了,拿这个来考三年级的小孩子!真是太BT了!还第三题!!! 二、解题思路 阅读全文
posted @ 2022-04-23 13:24 糖豆爸爸 阅读(297) 评论(0) 推荐(0) 编辑
摘要:#include<bits/stdc++.h> using namespace std; const int N = 110; struct Node { int weight; //重量 int volume; //体积 int money; //让利金额 } a[N]; /** 测试用例 10 阅读全文
posted @ 2021-11-25 10:47 糖豆爸爸 阅读(36) 评论(0) 推荐(0) 编辑
摘要:#include <bits/stdc++.h> using namespace std; const int N = 1010; int n, m; int v[N], w[N]; int f[N]; /** 测试用例: 80 2 18 10 30 20 */ //完全背包问题 int main( 阅读全文
posted @ 2021-11-25 10:17 糖豆爸爸 阅读(131) 评论(0) 推荐(0) 编辑
摘要:题目: #include<bits/stdc++.h> using namespace std; const int N = 1010; int n, m; int v[N], w[N]; int f[N]; int main() { //优化输入 ios::sync_with_stdio(fals 阅读全文
posted @ 2021-11-25 10:14 糖豆爸爸 阅读(172) 评论(0) 推荐(0) 编辑
摘要:题目描述: 一条绳子从中间剪一刀可以剪成两段绳子,如果对折1次,中间剪一刀可以剪出3段绳子,如果连续对折2次,中间剪一刀可以剪出5段绳子,那么,连续对折n次,中间剪一刀可以剪出多少段绳子? 通过编写程序,在给定绳子对折次数的情况下,计算出中间剪一刀后可剪出绳子的段数。 解题思路: 阅读全文
posted @ 2021-07-07 08:38 糖豆爸爸 阅读(649) 评论(0) 推荐(0) 编辑

Live2D
点击右上角即可分享
微信分享提示