蓝桥杯2018年第九届真题-小朋友崇拜圈(有向图强连通分量) 摘要:#include<bits/stdc++.h> using namespace std; #define maxx 310000 int a,n,anss; int ans[maxx]; v…… 题解列表 2023年08月21日 0 点赞 0 评论 251 浏览 评分:9.9
矩阵对角线求和简单解决 摘要:解题思路:主对角线特征:i=j副对角线特征:i+j=阶数注意事项:无参考代码:#include <stdio.h>int main (int argc, char *argv[]){ int s…… 题解列表 2023年08月20日 0 点赞 0 评论 228 浏览 评分:9.9
3152: 蓝桥杯2023年第十四届省赛真题-接龙数列 摘要:解题思路: 动态规划 用字符串来存,然后x是第一位,y是最后一位(比如22314 x=2 y=4) dp[y]表示以y数字为结尾的最长数列 每次当前放或者不放取最优的状态,…… 题解列表 2023年08月20日 0 点赞 0 评论 1447 浏览 评分:8.8
运用函数(递归)进行阶乘求和 摘要:解题思路:注意事项:参考代码:#include <stdio.h>long int f(int n);int main(){ int n; scanf("%d",&n); long int Sn=0;…… 题解列表 2023年08月20日 0 点赞 0 评论 338 浏览 评分:9.9
蓝桥杯2018年第九届真题-次数差 摘要:解题思路:利用字母ascii码进行统计。注意事项:出现0次不计入最小值参考代码:#include<bits/stdc++.h> using namespace std; int mxx,mnn;…… 题解列表 2023年08月20日 0 点赞 0 评论 251 浏览 评分:9.9
家人们,为什么这么写不对啊 摘要:解题思路:注意事项:参考代码:#include <stdio.h>#include<math.h>int main(){ int num[10], n, i, j, max; scanf("%d", …… 题解列表 2023年08月20日 0 点赞 2 评论 278 浏览 评分:6.0
2846: 统计数字字符个数 摘要:解题思路:了解字符串的处理注意事项:只需计算数字的个数,注意字符串结尾的'\0'参考代码:#include<stdio.h>#include<string.h> //处理字符…… 题解列表 2023年08月20日 0 点赞 0 评论 350 浏览 评分:0.0
[编程入门]超精简30行代码解决(容易理解) 摘要:解题思路:注意事项:参考代码:#include<stdio.h> struct stu{ char xh[10]; char xm[10]; int cj[3]; }…… 题解列表 2023年08月20日 0 点赞 0 评论 206 浏览 评分:9.9
2837: 年龄与疾病 摘要:解题思路:注意事项:参考代码:#include<stdio.h>int main(void){ int n,age[100],i; int a=0; //年龄在0-18 …… 题解列表 2023年08月20日 0 点赞 0 评论 278 浏览 评分:0.0
蓝桥杯2018年第九届真题-日志统计(复杂度O(nlogn)) 摘要:解题思路:首先记录每个日志的点赞时间,对每个日志的时间排序后,直接判断当前点赞时间和后k个时间是否差值小于d。注意事项:复杂度O(nlogn)参考代码:#include<bits/stdc++.h>…… 题解列表 2023年08月20日 0 点赞 0 评论 208 浏览 评分:6.0