主站
DreamJudge
院校信息
专业题库
模拟考试
机试真题
上岸课程
讨论区
兑换中心
登录
注册
上岸
西电机试专家
这个人很懒,什么都没有写...
关注
发消息
文章
0
题解
43
发帖
0
笔记
0
Ta的粉丝
24
关注数
0
粉丝数
24
获赞数
292
阅读数
6496
二叉树 题解:好看
#include<bits/stdc++.h> using namespace std; //思路,哪个数大,给哪个数除以2 int main () { int a,b; while(...
P1233
2025年2月28日 11:47
回复 0
|
赞 4
|
浏览 113
哈夫曼树 题解:求WPL的两种方法,图片详解
#include<bits/stdc++.h> using namespace std; //求WPL,换一种求法 int main(){ int n; //priorit...
P1382
2025年2月27日 11:36
回复 0
|
赞 11
|
浏览 181
合并果子 题解:果宝机甲,归位!
#include<bits/stdc++.h> using namespace std; int main(){ int n; priority_queue<int,vector&...
P1544
2025年2月27日 11:08
回复 0
|
赞 8
|
浏览 119
括号的匹配 题解:左压右出,四种错误情况
#include<bits/stdc++.h> using namespace std; //设置括弧的优先级 map<char,int> bkPriority = { {'<', 0}, {'(...
P1067
2025年2月26日 08:50
回复 0
|
赞 9
|
浏览 126
括号匹配 题解:用数组来模拟栈+知识点总结图示
#include<bits/stdc++.h> using namespace std; int main(){ string str;//初始字符串 cin>>str;&n...
P1501
2025年2月16日 12:04
回复 0
|
赞 4
|
浏览 165
幂次方 题解:我是范小勤,我不会
#include<bits/stdc++.h> using namespace std; long long x,n; const int N = 233333; long long pow(long long n){ long...
P1017
2025年2月16日 10:53
回复 0
|
赞 4
|
浏览 240
质因数个数 题解:计算机小白的拙劣题解
#include <bits/stdc++.h> using namespace std; //质因数:质因数就是一个数分解成最基础的质数相乘的形式,这些质数就叫它的质因数 //每个数的质因数分解是唯一的(比如12只能是2×2×3) //...
P1156
2025年2月12日 12:00
回复 0
|
赞 10
|
浏览 221
素数 题解:素数定义+判断思路
#include <bits/stdc++.h> using namespace std; //素数是指那些大于1,并且只能被1和它自己整除的数 //思路: 判断一个数是不是素数,即用它除以小于其根号的数[2-sqrt(i)],若能整除 则说明非素数 int m...
P1375
2025年2月12日 11:12
回复 0
|
赞 7
|
浏览 127
素数判定 题解:素数定义+整体思路
#include <bits/stdc++.h> using namespace std; //素数是指那些大于1,并且只能被1和它自己整除的数 //思路: 判断一个数是不是素数,即用它除以小于其根号的数[2-sqrt(i)],若能整除 则说明非素数 int m...
P1102
2025年2月12日 10:56
回复 0
|
赞 7
|
浏览 128
素数判定 - 哈尔滨工业大学 题解:素数定义+解题思路
#include <bits/stdc++.h> using namespace std; //素数是指那些大于1,并且只能被1和它自己整除的数 //思路: 判断一个数是不是素数,即用它除以小于其根号的数[2-sqrt(i)],若能整除 则说明非素数 int m...
P1355
2025年2月12日 10:31
回复 0
|
赞 9
|
浏览 213
判断素数 题解:素数定义+清晰思路
#include <bits/stdc++.h> using namespace std; //素数是指那些大于1,并且只能被1和它自己整除的数 //思路: 判断一个数是不是素数,即用它除以小于其根号的数[2-sqrt(i)],若能整除 则说明非素数 int m...
P1013
2025年2月12日 10:22
回复 0
|
赞 12
|
浏览 236
最简真分数 题解:约鬼吹灯算法
#include <bits/stdc++.h> using namespace std; //最简真分数 //定义:在真分数的基础上,分子与分母互质(最大公约数为1),即不可再约分的真分数。 int main(){ in...
P1180
2025年2月11日 15:10
回复 0
|
赞 3
|
浏览 115
求S(n) 题解:笨蛋小美的做法
#include <bits/stdc++.h> using namespace std; int main(){ int n; while(cin>&g...
P1500
2025年2月11日 11:32
回复 0
|
赞 11
|
浏览 296
链表合并 题解:我是马云,我要关闭电子游戏
#include <bits/stdc++.h> using namespace std; int main(){ int s1,s2; int a[101] ...
P1025
2025年2月10日 16:52
回复 0
|
赞 2
|
浏览 190
击鼓传花 题解:谁家的古风小孩可爱捏
#include <bits/stdc++.h> using namespace std; int main(){ int n; while(cin>&g...
P1018
2025年2月10日 15:49
回复 0
|
赞 15
|
浏览 281
猴子报数 题解:利用vector容器
#include <bits/stdc++.h> using namespace std; int main(){ int n,s,m;//s个猴子开始报数,第m个猴子退出报数 w...
P1081
2025年2月10日 15:26
回复 0
|
赞 10
|
浏览 229
猴子报数 题解:数组模拟,马+7我要给你生小猴子
#include <bits/stdc++.h> using namespace std; //思路:利用数组模拟,处理删除类问题可以考虑用其他方法进行,比如标记为删除,从而遍历之时将其跳过 int main(){ &nbs...
P1081
2025年2月10日 15:02
回复 0
|
赞 5
|
浏览 187
单链表 题解:不会真以为我会用链表吧孩子
#include<bits/stdc++.h> using namespace std; int main(){ int a[5]; for(int i=0;i<5;i++){ ...
P1015
2025年2月10日 14:48
回复 0
|
赞 7
|
浏览 315
查找学生信息2 题解:解释id只能用string类型的原因(超清晰,丁真看了都要抽一根瑞克五代)
在本题中,学号可能包含前导零(例如输入样例中的01,02)。如果使用int类型存储学号,这些前导零会被自动去除,导致以下问题: 学号唯一性被破坏 例如,学号01和001用int存储时都会变成1。这会导致不同学号被误认为相同,从而覆盖数据或错误匹配。 输入输出格式不一致 题目要求...
P1476
2025年2月9日 12:23
回复 0
|
赞 14
|
浏览 292
大整数排序 题解:马+7超绝简单易懂思路无敌坤坤打篮球版
#include <bits/stdc++.h> using namespace std; //思路:利用string的排序,若字符串长度相同,则根据ASCII排序, // 否则,长的元素更大 ...
P1412
2025年2月9日 12:09
回复 0
|
赞 15
|
浏览 243
1
2
3
本科学校:保密
目标学校:无
点此申请N诺身份认证
获得 noobdream 认证,享受多重认证福利!