友好城市 序列型动态规划,最长上升子序列 摘要:**先把河一边的城市升序排序,要求不交叉,还要足够多,那么问题就转化成河另一边城市的最长上升子序列问题** 那就简单了,代码如下 ```cpp #include #include using…… 题解列表 2022年03月30日 0 点赞 0 评论 516 浏览 评分:9.9
2281: 蓝桥杯2018年第九届真题-次数差 摘要:解题思路:注意事项:参考代码:t=input() dic={} for i in t: if i not in dic: dic[i]=1 else: …… 题解列表 2022年03月30日 0 点赞 0 评论 330 浏览 评分:0.0
python 解答方法 摘要:解题思路:注意事项:参考代码:x=list(map(int,input().split()))a=x[0]s1=0for i in range(1,a+1): s1+=ib=x[1]s2=0fo…… 题解列表 2022年03月30日 0 点赞 0 评论 324 浏览 评分:0.0
1066: 二级C语言-自定义函数(注意点) 摘要:注意事项:此题不难,细心点就可以,唯一注意:正数(x)要定义为double类型,其自定义函数返回类型要为double参考代码:#include<stdio.h> #include<math.h> …… 题解列表 2022年03月30日 0 点赞 0 评论 355 浏览 评分:0.0
阿尔法乘积(简单) 摘要:解题思路:注意事项:参考代码:#include<iostream>using namespace std;int main(){ int num; cin >> num; int temp = 1; …… 题解列表 2022年03月30日 0 点赞 0 评论 803 浏览 评分:9.9
轻轻松松六行搞定 摘要:解题思路:注意事项:参考代码:s=input();s1=set(s);s2= {"a","e","i","o", "u"};min=len(s) for i in s1 & s2: a=s…… 题解列表 2022年03月30日 0 点赞 0 评论 402 浏览 评分:9.9
编写题解 1808: [编程基础]输入输出练习之精度控制1 摘要:解题思路:注意事项:参考代码:#include<stdio.h>int main(){ float a; //单精度 scanf("%f",&a); //实型常量 %…… 题解列表 2022年03月30日 0 点赞 0 评论 298 浏览 评分:0.0
Sn的公式求和 摘要:解题思路:定义一个求和函数,在调用该函数计算Sn注意事项:。参考代码:#define _CRT_SECURE_NO_WARNINGS#include<stdio.h>int fun(int n){ …… 题解列表 2022年03月30日 0 点赞 0 评论 336 浏览 评分:0.0
1440: 蓝桥杯2013年第四届真题-带分数 dfs(JAVA题解) 摘要:解题思路:很暴力的暴力dfs,但要注意的是此题不要直接用字符串,否则会TLE,使用对10取余、叠乘,亦可达到效果(详见代码),且运行速度会大大提升。注意事项:参考代码:import java.io.*…… 题解列表 2022年03月30日 0 点赞 0 评论 880 浏览 评分:9.9
python 编写题解 1561: 蓝桥杯算法提高VIP-计算质因子 摘要:解题思路:注意事项:参考代码:import math def f(n): for i in range(2,int(math.sqrt(n)) + 1): if n%i=…… 题解列表 2022年03月30日 0 点赞 0 评论 293 浏览 评分:9.9