这个兄弟是真的能喝! 摘要:解题思路:每次都算出当前自己手中的空瓶(n)最多能换多少瓶饮料(k)以及剩下的临时空瓶子数量(a),并且将这些饮料(k)第一时间加到喝的总瓶数(count)中,然后将临时空瓶子的数量和刚刚喝掉的饮料产…… 题解列表 2022年01月18日 0 点赞 0 评论 336 浏览 评分:9.9
状压dp-矩阵计数(c++) 摘要:```cpp #include #include #include using namespace std; int dp[7][1m; int t=0,flag; fo…… 题解列表 2022年01月18日 0 点赞 0 评论 959 浏览 评分:9.3
蓝桥杯2014年第五届真题-分糖果 摘要:解题思路:注意事项:参考代码:#include<iostream> using namespace std; int main() { int n; cin>>n; …… 题解列表 2022年01月18日 0 点赞 0 评论 413 浏览 评分:9.9
状压dp-糖果(c++) 摘要:```cpp #include #include using namespace std; int dp[1n>>m>>k; int total=(1…… 题解列表 2022年01月18日 0 点赞 0 评论 774 浏览 评分:9.9
1151: C语言训练-计算一个整数N的阶乘 摘要:注意 0 的阶乘是 1。#include<bits/stdc++.h> using namespace std; void f(int &n){ if(n==0){ …… 题解列表 2022年01月18日 0 点赞 0 评论 273 浏览 评分:0.0
蓝桥杯算法提高VIP-理财计划 摘要:解题思路:注意事项:参考代码:#include<iostream>#include<cstdio>#include<math.h>using namespace std;int main(){ …… 题解列表 2022年01月18日 0 点赞 0 评论 391 浏览 评分:0.0
优秀的拆分,方法都会,注意细节即可,考察递归思想 摘要:解题思路: 一般来说,一个正整数可以拆分成若干个正整数的和。例如,1 = 1,10 = 1 + 2 + 3 + 4 等。 对于正整数 n 的一种特定拆分,我们称它为“优秀的”,当且仅当…… 题解列表 2022年01月17日 1 点赞 3 评论 717 浏览 评分:10.0
c++打印图案代码 摘要:解题思路:格式化输出就好了。注意事项:无参考代码:#include<bits/stdc++.h>using namespace std;int main(){printf(" *\n");print…… 题解列表 2022年01月17日 0 点赞 35 评论 1032 浏览 评分:9.9
蓝桥杯算法提高VIP-淘淘的名单 超简单 摘要:解题思路:注意事项:参考代码:#include<iostream>using namespace std;int main(){ string s; int N; cin>>N; …… 题解列表 2022年01月17日 0 点赞 0 评论 306 浏览 评分:0.0
校门外的树 c++ 摘要:解题思路:注意事项:参考代码:#include <iostream>using namespace std;int main(){ int L,M; cin>>L>>M; bool a[L+1]={f…… 题解列表 2022年01月17日 0 点赞 0 评论 300 浏览 评分:0.0