主站
DreamJudge
院校信息
专业题库
模拟考试
机试真题
专业课程
讨论区
兑换中心
登录
注册
上岸
搜索
全 部
择校分析
笔经面经
学习交流
我要提问
站内公告
调剂专题
精彩爆料
解题报告
数据结构 1074
有两个循环链表,链头指针分别为L1和L2,要求写出算法将L2链表链到L1链表之后
y741934193
回复 9+
|
赞 0
|
浏览 25.5k
void merge(Lnode *L1,Lnode *L2){ Lnode *p=L1;Lnode *q=L2; while (p->next!=L1) p=p->next; //找到L1链尾 while (q->next!=L2) q=q->nex...
P1377
旋转矩阵 - 北航 题解:
flipped
回复 0
|
赞 0
|
浏览 33
#define _CRT_SECURE_NO_WARNINGS #include <stdio.h> #include <stdlib.h> #include <stdbool.h> #include <math.h>...
P1018
击鼓传花 题解:
flipped
回复 0
|
赞 0
|
浏览 38
#define _CRT_SECURE_NO_WARNINGS #include <stdio.h> #include <stdlib.h> #include <stdbool.h> #include <math.h>...
P1062
杨辉三角形 题解:
flipped
回复 0
|
赞 0
|
浏览 41
#define _CRT_SECURE_NO_WARNINGS #include <stdio.h> #include <stdlib.h> #include <stdbool.h> #include <math.h>...
站内公告
N诺意见反馈专帖
admin
SVIP
回复 144
|
赞 8
|
浏览 52.6k
Hi,你好,我们是N诺。我们是一个为了您考研更方便的存在,您可以理解成我们是一个题库,一个刷题的工具,一个学习的渠道,或者,一个认识更多志同道合计算机考研er的平台。 我们一直在努力,为了你使用过程更加流畅和顺利。所以如果你有任何吐槽,都请在评论中表达出来,让我们知晓 。 如果反馈的问题没...
P1334
最大连续子序列 题解:
为欢几何
回复 0
|
赞 0
|
浏览 44
#include<bits/stdc++.h> using namespace std; long long dp[1000010]; long long a[1000010]; long long maxx; long long s = 0, d = 0; lon...
P1098
前缀字符串 有大佬可以帮忙看一下错在哪里吗?
等等
回复 2
|
赞 0
|
浏览 127
#include<bits/stdc++.h> using namespace std; bool compair(const string& s1, const string& s2){ if (s1.size() > ...
P1655
北邮2019 最短路径 Floyd:wrong error50%
为欢几何
回复 1
|
赞 0
|
浏览 96
//Floyd模板 #include<bits/stdc++.h> using namespace std; #define INF 0x3f3f3f3 const int maxn = 105; int mpt[maxn][maxn]; int edge[maxn...
P1176
十进制和二进制 50%通过率,有大佬可以帮忙看看吗
等等
回复 2
|
赞 0
|
浏览 152
#include<bits/stdc++.h> using namespace std; int main() { char a[200],buf[200]; int b[200]; &n...
复旦大学
复旦大学工程与应用技术研究院2024年硕士研究生招生考试进入复试考生名单
考研小助手
回复 0
|
赞 0
|
浏览 140
复旦大学
复旦大学软件学院2024年全日制硕士研究生招生考试进入复试考生名单
考研小助手
回复 0
|
赞 0
|
浏览 134
北京大学
计算机学院2024年硕士统考考生、港澳台生复试工作安排(含复试名单)
考研小助手
回复 0
|
赞 0
|
浏览 126
一、复试规则 1.复试分数线 普通计划总分:380分 普通计划单科:政治55分,外语55分,专业课一90分,专业课二90分。 专项计划:执行学校的政策。 2.复试基本内容:包括上机考试、专业知识、科研能力、逻辑思维与表达能力、英语听力及口语...
P1333
开门人和关门人 题解:
mshj
回复 0
|
赞 0
|
浏览 86
#include<iostream> #include<algorithm> using namespace std; int main() { int n; while (cin >&g...
P2021
整数去重 题解:
sleepysilipu
回复 1
|
赞 0
|
浏览 96
一个暴力解,时间复杂度过高故通过不了评测。 思路:双重for循环,重复项标记为-1 #include<stdio.h> int main(){ int n,i,j; scanf(&...
P1563
迷宫 题解:AC
为欢几何
回复 2
|
赞 0
|
浏览 115
//迷宫问题求起点到终点的最短路径(自己写的代码) #include<bits/stdc++.h> using namespace std; struct node { int x; int y; &nbs...
P1082
Hanoi塔问题 题解:注意输出格式,相邻输出之间有3个空格
为欢几何
回复 0
|
赞 0
|
浏览 73
//汉诺塔输出每一个步骤,五个一换行 #include<bits/stdc++.h> using namespace std; int step;//记录移动步数 void Hanoi(int n, char a, char b, char c) { ...
P1417
八进制 题解:
Amberqwe
回复 2
|
赞 0
|
浏览 189
只有80%,为什么啊 #include<stdio.h> int main() { int n,x; int a[1000000]; int m=0; &nb...
P1562
哈夫曼编码 题解:通过率50%,哪种情况没考虑到呢?
为欢几何
回复 2
|
赞 0
|
浏览 95
//输出字符串最佳无前缀可变长度编码的位长度 #include<bits/stdc++.h> using namespace std; int main() { string s; while(cin >&...
P996
二叉搜索树 - 复旦2020 题解:Time Limit Exceeded 90
为欢几何
回复 3
|
赞 0
|
浏览 144
#include<bits/stdc++.h> using namespace std; int temp[100001]; struct Tree { int data; struct Tree* lchild; struct Tree* ...
P5131
多种排序 题解:
Qweas
回复 0
|
赞 0
|
浏览 68
#include <iostream> #include <vector> #include <algorithm> // 直接插入排序 void insertionSort(std::vector<int>& arr) ...
P1382
哈夫曼树 题解:最简单易懂的思路,AC
为欢几何
回复 2
|
赞 0
|
浏览 139
//哈夫曼树,输出所有结点的值与权值的乘积之和 #include<bits/stdc++.h> using namespace std; int main() { int n; while(cin >> n) { int ...
P1221
旋转矩阵 题解:
yangke
回复 0
|
赞 0
|
浏览 96
#include <iostream> #include <algorithm> using namespace std; int n, m, k; int manu; int res[101][101]; int a[101][101]; int mai...
P1047
分数求和 题解:规律就是a是a+b,b是上一次的a,注意要用double或者fl
RingoCrystal
回复 0
|
赞 0
|
浏览 89
#include <bits/stdc++.h> using namespace std; double sumAns(int N) { double sum = 0; double a = 2, b = 1; // 初始的前两项 for ...
P1031
判断是否是整数 题解:3.000算整数
RingoCrystal
回复 0
|
赞 0
|
浏览 97
#include <bits/stdc++.h> using namespace std; int main(){ string s; while(cin>>s){ int flag=0; int tag=0; for(int i=...
P1045
平方和与倒数和 题解:如何获得float,很简单1.0/i
RingoCrystal
回复 0
|
赞 0
|
浏览 92
#include <bits/stdc++.h> using namespace std; int main(){ int a,b,c; cin>>a>>b>>c; float ansa=0; for(int i=1;...
P1044
阶乘和 题解:考虑到数据的容量,使用longlong改写n!即可
RingoCrystal
回复 0
|
赞 0
|
浏览 90
#include <stdio.h> long long getF(long long a){ if(a==0||a==1)return 1; return a*getF(a-1); } int main(){ int n; scanf("%d",...
P1685
爬楼梯游戏 题解:C语言解法
快乐小土狗
回复 0
|
赞 0
|
浏览 94
#include <stdio.h> int mod=1e9+7; int dp[1000005];//要先填充dp再进行多组输入,否则会超时 int main() { int n; dp[0]=1,dp[1]=1; for(int i=2;i<=...
P2009
温度转换计算 题解:
G517
回复 0
|
赞 0
|
浏览 93
很基础的一道 #include <stdio.h> int main(void) { double celsius; double fahrenheit; scanf("%lf", &fahrenheit); ...
综合
二叉树的最近公共祖先
酷酷兔
回复 0
|
赞 0
|
浏览 111
class Solution { public TreeNode lowestCommonAncestor(TreeNode root, TreeNode p, TreeNode q) { if(root == null || root == p || root...
P1410
打印日期 题解:遍历题,注意break,不break在输入2000 31的时候会
RingoCrystal
回复 0
|
赞 0
|
浏览 71
这种题的本质就是单纯的顺序检索题,这个代码还可以优化,就是不用day,直接在else情况下break,此时输出为year,month,n,注意输出的格式 #include <bits/stdc++.h> using namespace std; int...
P1000
A+Bproblem (c++)<----抓换的思想
jerry3128
回复 6
|
赞 2
|
浏览 14.4k
这道题是我在本站上A的第一道题,那我们直接开始吧: 首先,我们要用到转换的思想,既然这道题跟代数有关,那我们便可以把它转换为图论,如图: 又因为在题目的数据中并没有负数,那么,显然这个问题就转化为了求源点S到汇点T的最大流,接着就是模板就行了 #include<bits...
1
2
3
...
296
我要提问
近期热门
1
N诺成就值出炉,帮你一眼识别大神
2
机试如何才能快速提高?
3
[置顶]计算机考研择校分析【25考研必读】
4
广度优先搜索计算每个人移动到每个位置需要去掉障碍物的最少数目,最后求和的最小值
5
1377旋转矩阵
6
ip地址(C)
7
简单易懂
8
C++递归解法,有注释
9
1017 幂次方 快速幂模板
10
计算机考研复试笔记——操作系统篇