蓝桥杯算法提高VIP-质因数2 摘要:解题思路:用while跳过质数判断注意事项:参考代码:n = int(input())s = str(n)+'='lis = []for i in range(2, n+1): …… 题解列表 2023年04月03日 0 点赞 0 评论 311 浏览 评分:9.9
2680: 蓝桥杯2022年第十三届省赛真题-纸张尺寸 摘要:解题思路:只用考虑输入的0~9这几个数,做循环就行注意事项:参考代码:name = input() num = int(name[1]) #只看A后面的数 l=1189 #长 w=8…… 题解列表 2023年04月03日 0 点赞 4 评论 832 浏览 评分:9.9
###[编程入门]结构体之时间设计-超easy版!! 摘要:###[编程入门]结构体之时间设计-超easy版!! 主要分四步: 1. 创建结构体 2. 判断年份是否为闰年 3. 记录各月份的总天数 4. 对天数累加 先看代码 #i…… 题解列表 2023年04月03日 0 点赞 0 评论 305 浏览 评分:9.9
Fibonacci数列——递归 摘要:解题思路:注意事项:参考代码:def fb(n): if n == 1 or n == 2: return 1 else: return fb(n-1)+fb(…… 题解列表 2023年04月03日 0 点赞 0 评论 322 浏览 评分:9.9
C++递归求解 摘要:解题思路:注意事项:参考代码:#include <iostream>#include <vector>using namespace std;vector<int> f[100050];int dfs…… 题解列表 2023年04月03日 1 点赞 0 评论 346 浏览 评分:9.9
蓝桥杯2022年第十三届省赛真题-重新排序 摘要:解题思路:前缀和和差分数组减少运算量注意事项:不要超时和使用long long参考代码:#include <iostream> #include <vector> #include <set> …… 题解列表 2023年04月03日 0 点赞 1 评论 428 浏览 评分:9.9
蓝桥杯2022年第十三届省赛真题-技能升级 摘要:解题思路:可用二分法先找到升级m次可以达到的最大的攻击力增量x,则前面那些次升级的攻击力必大于x注意事项:不要超时参考代码:#include #include #include #include #i…… 题解列表 2023年04月03日 0 点赞 0 评论 1023 浏览 评分:9.9
题解 1097: 蛇行矩阵 摘要:解题思路:女朋友写的,思路非常好,直接将小蛇蛇排进数组,代码简洁明了注意事项:参考代码:import java.util.Scanner; public class Main { pu…… 题解列表 2023年04月04日 0 点赞 0 评论 215 浏览 评分:9.9
用辗转相除法也可以算,菜鸟运算 摘要:参考代码#include<stdio.h>int main(){int a,b;int t,c;scanf("%d %d",&a,&b);int i,j;i=a,j=b;while(b!=0){ t=…… 题解列表 2023年04月04日 0 点赞 0 评论 239 浏览 评分:9.9
大模拟题,使用结构体和sort以及闰年判断 摘要:解题思路:注意事项:参考代码:#include<iostream> #include<cstdio> #include<algorithm> using namespace std; stru…… 题解列表 2023年04月04日 0 点赞 0 评论 215 浏览 评分:9.9