母牛的故事 (C++代码) 摘要:解题思路:因为小牛要隔三年才能生崽,因此申请一个数组保存每年新出生的牛犊的数,等到三年后成熟,将它们加入可以生崽的队伍中。注意事项:设当前为第n年,每年先从 unm[(n+1)%4]中取出成熟的…… 题解列表 2019年03月20日 0 点赞 0 评论 1288 浏览 评分:0.0
发工资咯 (C++代码)又水了一发 摘要:参考代码:#include<bits/stdc++.h> #define hh ios::sync_with_stdio(false),cin.tie(0),cout.tie(0); using …… 题解列表 2019年03月20日 0 点赞 0 评论 1652 浏览 评分:0.0
等待戈多 (C++代码) 摘要:解题思路:注意事项:参考代码:#include<iostream> #include<algorithm> #define MAX 99999 using namespace std; d…… 题解列表 2019年03月20日 0 点赞 0 评论 1854 浏览 评分:0.0
汉诺塔 (C++代码) 摘要:解题思路:注意事项:参考代码:#include <iostream> using namespace std; void move(int &n, char &x, char &y) { …… 题解列表 2019年03月20日 0 点赞 0 评论 1436 浏览 评分:6.0
蓝桥杯算法提高VIP-分苹果 (C++代码) 摘要:解题思路:言归正传,所谓差分数组,就是说假设有两个数组d[i],a[i],d[i]=a[i]-a[i-1],d[0]=a[0],那么d[i]就是a[i]的差分数组,d[i]的前缀和就是a[i],即a[…… 题解列表 2019年03月19日 0 点赞 0 评论 1861 浏览 评分:0.0
蓝桥杯2017年第八届真题-包子凑数 (C++代码) 摘要:解题思路:注意事项:参考代码:#include <stdio.h> #include <iostream> #define N 20000 using namespace std; i…… 题解列表 2019年03月19日 0 点赞 0 评论 1223 浏览 评分:0.0
蓝桥杯算法提高VIP-逆序排列 (C++代码) 摘要:解题思路:注意事项:参考代码:#include<stdio.h>#include<string>#include<algorithm>#include<cstring>#include<iostrea…… 题解列表 2019年03月19日 0 点赞 0 评论 764 浏览 评分:0.0
蓝桥杯算法训练VIP-特殊的数字四十 (C++代码) 摘要:解题思路:注意事项:参考代码:#include<iostream>using namespace std;bool isShi(int n){int sum=0;while(n){sum=sum+n%…… 题解列表 2019年03月19日 0 点赞 0 评论 1018 浏览 评分:0.0
蓝桥杯算法训练VIP-水仙花 (C++代码) 摘要:解题思路:注意事项:参考代码:#include<iostream>#include<cmath>using namespace std;bool isShui(int n){int sum=0;int…… 题解列表 2019年03月19日 0 点赞 0 评论 1272 浏览 评分:0.0
矩阵最大值 (C++代码)又水了一题 摘要:<浪费空间的做法,不过还是可以A的>#include<bits/stdc++.h> #define hh ios::sync_with_stdio(false),cin.tie(0),cout.ti…… 题解列表 2019年03月19日 0 点赞 0 评论 1698 浏览 评分:0.0