信息学奥赛一本通T1346-亲戚(relation) 并查集 此题有毒 摘要:解题思路:注意事项:参考代码:#include<bits/stdc++.h>using namespace std;const int MAXN = 20010;int father[MAXN];in…… 题解列表 2024年10月19日 0 点赞 0 评论 412 浏览 评分:9.9
求平均工资 摘要:参考代码:n=int(input()) nn=n sum=0 while n!=0: a=int(input()) sum+=a n-=1 print(sum//…… 题解列表 2024年10月19日 0 点赞 0 评论 486 浏览 评分:0.0
[蓝桥杯2022年第十三届决赛真题-最大数字] 贪心+dfs 摘要:# 咋还给我爆long long了啊这题 ```cpp #include #define ULL unsigned long long #define LL long long #def…… 题解列表 2024年10月19日 0 点赞 0 评论 484 浏览 评分:9.9
试图解释答案为什么是F E 摘要:解题思路:1.看题目要求,本题要求输出选项ABC,2.先判断选项所代表的数据类型,和a,b输出的数据类型,再看看题目所写的代码有没有强制类型转换,不过本题没有强制类型转换,所以可以不用考虑,3.判断题…… 题解列表 2024年10月19日 2 点赞 0 评论 507 浏览 评分:9.9
小小练手(自学菜鸡版) 摘要:解题思路:如下注意事项:注意左对齐,(作者用了判断语句,但其实用%2.d最好了)参考代码:#include <stdio.h>int main(){ int a,b,c; for(a =1; a<10…… 题解列表 2024年10月19日 0 点赞 0 评论 611 浏览 评分:0.0
写短一点点 摘要:解题思路:直接输出注意事项:Hello, World!。”,“后面有一个空格要带上,”!“也不要省,建议直接复制粘贴题目的Hello, World!参考代码:#include"stdio.h"main…… 题解列表 2024年10月19日 1 点赞 0 评论 472 浏览 评分:0.0
寻梦之C++解题 摘要:#include<iostream> #include<string> using namespace std; int main() { int n; string s1, s2;…… 题解列表 2024年10月19日 0 点赞 0 评论 130 浏览 评分:0.0
使用嵌套数组解决 摘要:解题思路:python中无法创建矩阵,但是可以使用数组进行模拟矩阵,模拟后使用max函数和abs函数进行输出绝对值最大值,最后使用遍历找出数组的位置,因为数组的位置是从0开始,所以最后i,j坐标分别都…… 题解列表 2024年10月19日 0 点赞 0 评论 224 浏览 评分:9.9
数字的处理与判断 摘要:解题思路:转化为字符串问题注意事项:字符串反转,双指针参考代码:#include<bits/stdc++.h>using namespace std;string ver(string s){//反转…… 题解列表 2024年10月19日 0 点赞 0 评论 295 浏览 评分:0.0
可以判断空格不输出 摘要:解题思路:注意事项:参考代码:#include<string.h>int main(){ int i,a,b; char str1[100],str2[100]; gets(str1); get…… 题解列表 2024年10月18日 0 点赞 0 评论 289 浏览 评分:9.9