python(简单直白) 摘要:解题思路: 注意事项: 开头和结尾字符单独比较。 中间字符比较时,如果可以完成替换操作,则需执行替换,否则会对后续字符比较产生影响。 参考代码: ## 翻转 D=int(i…… 题解列表 2024年04月02日 0 点赞 0 评论 502 浏览 评分:6.0
蓝桥杯2013年第四届真题-大臣的旅费 摘要:解题思路:求树的直径,在使用等差数列的前n项和得出答案.因为全为正数所以可以跑两边最长路就可以求出,此处给出树上dp参考代码:#include<bits/stdc++.h> using namesp…… 题解列表 2024年04月02日 0 点赞 0 评论 410 浏览 评分:0.0
Jayden-[解释通俗易懂,一看就会! ] 自定义函数之通用位移 摘要:解题思路:在move函数中根据n的正负来决定value是左移还是右移: n >= 0: 右移。使用>>运算符将value右移n位,并使用<< 运算符将value左移bits-n位,最后将两个结…… 题解列表 2024年04月02日 1 点赞 0 评论 833 浏览 评分:9.9
2838: 有趣的跳跃 python (正确运行,简单易懂) 摘要:解题思路:注意事项:参考代码:import mathlistB = []listC = []listA = list(map(int,input().split()))n = listA.pop(0)…… 题解列表 2024年04月02日 1 点赞 0 评论 775 浏览 评分:9.5
高级无磨损 崭新出厂 摘要:解题思路:注意事项:可以把成绩定义成int型参考代码:#include <stdio.h>struct Student{ char num[20]; char name[20]; float scor…… 题解列表 2024年04月02日 0 点赞 0 评论 404 浏览 评分:9.9
2825: 计算多项式的值 摘要:解题思路:由题目可知,该多项式是等比数列之和,因此我们要找到他的通项公式通项公式为:a n =a的1次方*x的n-1次方注意事项:参考代码:#include<stdio.h> int main(){…… 题解列表 2024年04月02日 0 点赞 0 评论 447 浏览 评分:0.0
python (超时参考,73通过)(官网好像AC了) 摘要:解题思路: 主要是贪心思路(先进行排序) (个人比较菜会超时,如果有小伙伴知道怎么解决请不吝赐教) 注意事项: 参考代码: ##平均 import sys sys.set…… 题解列表 2024年04月02日 0 点赞 0 评论 512 浏览 评分:7.0
蓝桥杯2013年第四届真题-带分数 摘要:解题思路:使用全排列函数枚举,后枚举三个数的位数,计算一遍a+b/c就好注意事项:参考代码:#include<bits/stdc++.h> using namespace std; int mai…… 题解列表 2024年04月02日 0 点赞 0 评论 345 浏览 评分:0.0
蓝桥杯2023年第十四届省赛真题-子串简写 摘要:解题思路:注意事项:参考代码:常人思路(超时)#include <bits/stdc++.h> using namespace std;int K;long long ans=0;string S;c…… 题解列表 2024年04月02日 2 点赞 0 评论 1166 浏览 评分:9.9
字典解决法,简单 摘要:解题思路:用排除法来判断是否有解法,踢去不可能的,则是存在的注意事项:参考代码:s1 = input().strip() s2 = input().strip() s3 = input().str…… 题解列表 2024年04月02日 0 点赞 0 评论 481 浏览 评分:9.9