1331: 新三国争霸 摘要:# 1331: 新三国争霸 ```cpp /* * 1331: 新三国争霸 * 被通过率骗啦,还是比较综合的题目,考察了dp,图论。 * 简化一下题目,先考虑剔除转变驻守的策略。题目…… 题解列表 2024年01月18日 0 点赞 0 评论 286 浏览 评分:0.0
[编程入门]完数的判断 摘要:解题思路: 双重循环找完数,并把每个因子储存到数组里面;注意事项:注意将数组和求和数据归零;参考代码:#include<bits/stdc++.h>using namespace std;int ma…… 题解列表 2024年01月18日 0 点赞 0 评论 154 浏览 评分:0.0
1120: C语言训练-"水仙花数"问题2 摘要:解题思路:注意事项:参考代码:#include <bits/stdc++.h>using namespace std;int main(){ long long a,b,c; for(in…… 题解列表 2024年01月18日 0 点赞 0 评论 113 浏览 评分:0.0
[编程入门]迭代法求平方根 摘要:解题思路: 注意事项:参考代码:#include<bits/stdc++.h>using namespace std;int main() { double x1 , x2 , k; cin >> k…… 题解列表 2024年01月18日 0 点赞 0 评论 216 浏览 评分:0.0
题解 2831: 画矩形 摘要:解题思路:注意事项:参考代码:#include <iostream>using namespace std;int main(){ int a,b,d; char c; cin>>a…… 题解列表 2024年01月18日 0 点赞 0 评论 141 浏览 评分:0.0
简单方法实现数字逆序输出 摘要:解题思路:创建数组存储数据,利用两个for循环即可实现第一个for循环:用于拿到用户输入的10个数字,存入数组第二个for循环:倒着输出创建的数组注意事项:参考代码:#include<iostream…… 题解列表 2024年01月18日 0 点赞 0 评论 406 浏览 评分:0.0
2825: 计算多项式的值 摘要:解题思路:注意事项:参考代码:#include<bits/stdc++.h>using namespace std;int main(){ double x,a,sum = 0;//要复出值 …… 题解列表 2024年01月18日 0 点赞 0 评论 129 浏览 评分:0.0
1155基础解法(Python) 摘要:解题思路:随手写的,没有优化注意事项:重点在于如何实现字典序,然后要保证答案格式正确即可参考代码:import mathdic = {}count = 1func = lambda x : math.…… 题解列表 2024年01月18日 0 点赞 0 评论 209 浏览 评分:0.0
C语言-计算2的幂 摘要:解题思路:循环结构,n个2相乘注意事项:参考代码:#include<stdio.h>#include <math.h>int main(){ int n,s=1; scanf("%d",&…… 题解列表 2024年01月18日 0 点赞 0 评论 163 浏览 评分:0.0
[编程入门]选择排序 摘要:# ## 第一次从待排序的数据元素中选出最小 的一个元素,存放在序列的起始位置,然后再从剩余的未排序元素中寻找到最小元素,然后放到已排序的序列的末尾 。以此类推,直到全部待排序的数据元素的个数为零。…… 题解列表 2024年01月18日 0 点赞 0 评论 209 浏览 评分:0.0