首页
DreamJudge
院校信息
专业题库
模拟考试
机试真题
上岸课程
兑换中心
登录
注册
上岸
搜索
推 荐
择校分析
笔经面经
学习交流
我要提问
站内公告
调剂专题
精彩爆料
解题报告
P1600
2个问题请问
chenziyi
回复 2
|
赞 1
|
浏览 7.8k
1. 边界条件为什么只写一个dp[0][1]=1;而不是dp[1][0]=1; 实验了一下都能ac。 2.题目的要求不是最后的结果求余吗 为什么都是在递推过程中求余。
P1388
查找1 题解:bool数组标记+map标记
18919717626
回复 0
|
赞 1
|
浏览 603
bool数组标记 #include <iostream> #include <string.h> using namespace std; int n,m,a[1000],x,f[1000]; int main(){ int n; ...
P1021
复数 题解:c++struct 和 运算符重载实现
damowanghwj
回复 0
|
赞 1
|
浏览 640
#include<bits/stdc++.h> using namespace std; struct Complex{ double real; double image; Complex operator + (const Complex ...
P1019
第一想法就是用string做,请各位多指教
1435647858
回复 0
|
赞 2
|
浏览 8.5k
#include<bits/stdc++.h> using namespace std; int main(){ string s,t; getline(cin,s); ...
P1404
成绩排序(函数sort) - 华科 题解:
Candour
回复 0
|
赞 5
|
浏览 313
#include<bits/stdc++.h> using namespace std; const int N = 1010; int n; struct student{ string name; int age; int score; }s[...
P1036
C_冒泡排序法求最大值
nooknook
回复 0
|
赞 2
|
浏览 8.0k
#include<stdio.h> #define N 3 int main() { int a[N]; int i, j, t; for (int i = 0; i < N; i++) scanf("%d", &a[i]); for ...
P1426
最大公约数1(空间复杂度O(1)) 题解:
Candour
回复 0
|
赞 12
|
浏览 929
没开数组,优化了内存,时间复杂度O(n) #include<bits/stdc++.h> using namespace std; int n; int main() { int a = INT_MAX, b = -1; scan...
P1007
整除 题解:
lingdongyang
回复 0
|
赞 15
|
浏览 1.2k
#include<stdio.h> int main() { int cnt = 0; for (int i = 100; i <= 1000; i++) { if (i % 30 == 0) { cnt++; if (cnt != 1...
P5105
集合中的相同元素 题解:
jaygee_
回复 0
|
赞 2
|
浏览 159
#include<bits/stdc++.h> using namespace std; int main() { int n; cin >> n; vector<int> a(n), b(n); ...
P1359
数字阶梯求和 题解:弱智判题给我整笑了
RingoCrystal
回复 2
|
赞 4
|
浏览 248
#include <bits/stdc++.h> using namespace std; void stringPlus(string &a,string b){ string c; while(a.size()!=b.size()){ ...
P1109
P1109 解题思路分享
杨德胜
回复 0
|
赞 2
|
浏览 10.6k
#include <bits/stdc++.h> using namespace std; typedef struct BinNode{ char e; struct BinNode* lchild; struct BinNode* rchild; }B...
P1561
无需建树,核心代码 6 行
Yemonade
回复 1
|
赞 5
|
浏览 5.7k
# include <iostream> # include <algorithm> # include <unordered_map> using namespace std; string pre, ino; unordered_map...
P1907
差分计数 题解:输入数据量很大的时候,建议使用scanf
快乐小土狗
回复 0
|
赞 4
|
浏览 180
根据满分篇的内容 C++加速还是不如scanf速度快 #include <stdio.h> #include <stdlib.h> #define MAX_N 2000000 #define MAX_VAL 4000001 #define...
P1034
题本本身不难,就是输出格式上需要注意
sincerely_LM
回复 0
|
赞 2
|
浏览 8.8k
#include <stdio.h> #include <stdlib.h> #include <stdbool.h> int main(int argc, char const *argv[]) { bool found; ...
P1500
求S(n) 题解:C
lingdongyang
回复 0
|
赞 5
|
浏览 794
#include<stdio.h> int main() { int n; while (scanf("%d", &n) != EOF) { int sum = 0; sum = sum + (n % 3 * n % 3 * n % 3 *...
P1454
反序数 题解:其实循环条件是9*n<10000
quyang
回复 0
|
赞 2
|
浏览 250
#include<iostream> using namespace std; int main(){ int n=1000; while(9*n<10000){  ...
西北农林科技大学
2021调剂上岸西北农林科技大学经验帖
woshipzg123
回复 0
|
赞 2
|
浏览 5.9k
2021双非科班调剂985(一志愿中科大,调剂上岸西北农林科技大学)初试复试经验帖 马上毕业啦,回想过去的一年想通过这一份经验帖给自己的大学画上一个圆满的句号,很多同学应该看过其他学长学姐各种各样的经验帖和各科的时间规划,本文就不过多谈各科的时间安排,主要是阐述自己这一年各科踩过的坑以及...
P1738
1738 前缀合+差分复习
青缘
回复 0
|
赞 14
|
浏览 6.0k
看到这种题目 “给定q个查询...”能够很明显的定位到用前缀合解决。因为虽然算法本身时间复杂度还过得去,但是每次查询都要经过一次计算,查询次数一多,非常容易超时。所以一定是先算再存再查,提高效率。 解题思路 判断两个子串中每个...
P1032
变位词 题解:先sort()排序再比较
遨游
回复 0
|
赞 6
|
浏览 1.1k
#include <iostream> #include <string> #include <algorithm> using namespace std; bool judge(string s1,string s2){  ...
P1177
查找学生信息 题解:C语言 要特别注意有多组输入数据
carrot_huan
回复 0
|
赞 3
|
浏览 997
#include<stdio.h> int main() { int n,m; while(scanf("%d %d",&n,&m)!=EOF){ int data[200]; for(int i=0;i<n;i++) &n...
P1311
继续畅通工程 题解:稍微修改1312
阿离
回复 0
|
赞 9
|
浏览 874
#include <bits/stdc++.h> using namespace std; const int maxn=105; int fa[maxn]; struct node{ int u,v,w,m; }edge[maxn*maxn]; i...
P1533
单链表节点交换 题解:C++
小王桐学
回复 0
|
赞 1
|
浏览 719
#include <stdio.h> #include <stdlib.h> typedef struct node{ int data; struct node *next; }LNode,*LinkList; //初始化链表 void ...
P1698
皇天不负有心人啊!!!!
1917000346
回复 1
|
赞 3
|
浏览 8.7k
#include <bits/stdc++.h> using namespace std; #define MAX 10000000 int main() { char s[10000]; string c;//暂...
华南理工大学
18华工【计算机】考研总结--复试篇
姚清
回复 0
|
赞 1
|
浏览 13.3k
总述:考研,是一场信息战。 是的。接上一篇--初试篇。 先说一下今年(2018)的情况: 1.统考生过复试线99人,招66人 2.复试内容有:机试(30%) + 面试(60%) + 英语口语(10%,在面试环节进行) 以及最后考研综合分数的计算方法: (初试 + 复试*...
P1377
小白一枚
寂寞圣哲
回复 0
|
赞 3
|
浏览 12.1k
本题总体思路为只要写出将数组旋转90的代码就行,因为旋转180度思路是一样的,无非就是把旋转90的方阵再次旋转90,270也一样。 所以难点在于写出旋转90的方法,如何找出原数组和旋转90的数组的关系,分析如下: 原数组 1 2 3...
P1155
反序输出 题解:C
小王桐学
回复 0
|
赞 5
|
浏览 873
#include <stdio.h> #include <string.h> void Reverse(char *s) { char *p = s; while(*p != '\0') p++; p--; while(p >= s)...
P1610
于是他错误的点名开始了 题解:男人,什么罐子我说,曼巴蛇出去
zxjrheaven
回复 0
|
赞 2
|
浏览 176
#include <bits/stdc++.h> using namespace std; //思路:结构体数组,遍历之,先试试,害怕超时 //struct node //{ // int vis={0}; // &nb...
P1278
阶乘处理&&循环求和
机试帐号
回复 0
|
赞 4
|
浏览 10.3k
这个题是入门题,我认为有两个关键点:一是看到阶乘,我第一反应就是打表,因为阶乘的运算耗时太久,一看n的取值1000000,就觉得可行,我看有些朋友用的自定义阶乘函数打表,我觉得不如直接手动算出阶乘,输入数组。第二不是很重要,这里要求找是否能够通过求值得到,作差是一个常见的方法,在涉及数组求和的...
P1125
求三角形的面积 题解:为啥过不去
李志豪
回复 1
|
赞 1
|
浏览 112
#include<stdio.h> #include<math.h> int main(){ float x1,y1,x2,y2,x3,y3; float s;  ...
西北农林科技大学
2017西北农林科技大学计算机考研复试回忆
JackRepsy
回复 0
|
赞 1
|
浏览 14.6k
写这篇帖子的初衷是15,16届的师兄热心发帖,给了我很大的帮助,所以想尽自己的绵薄之力,将这份帮助传递下去,希望能帮助更多的人。 2.15号出成绩,出了成绩就知道一志愿去不了,开始找调剂,最后确定为西农。开始联系导师,导师回复很快,但是也很官方,联系研招办询问情况。这期间需要不断关注信工的官...
P1740
素数筛,然后再判断是否包含4
Fairy渚薰
回复 1
|
赞 7
|
浏览 8.8k
#include<bits/stdc++.h> using namespace std; const int N=1e7+10; int vis[N]; int prime[N]; int cnt=0; int ans; //bool judge(int x){ /...
P2011
字符串替换 题解:find+replace
阿灿
回复 0
|
赞 4
|
浏览 226
#include<bits/stdc++.h> using namespace std; int main(){ string str; int flag=0; cin>>str; transform(str.begin(), str.end()...
P1020
最长连续因子 题解:
gzulianxisheng
回复 0
|
赞 1
|
浏览 566
#include <bits/stdc++.h> using namespace std; int main(){ int n; cin >> n; ...
P1506
缺页问题 题解:异或
Syou
回复 0
|
赞 3
|
浏览 1.4k
C++ 异或:异或同一个数2次或者偶数次,那么本身的值不变。 #include <iostream> using namespace std; int main(){ int N; int sum = 0; cin >> N; for...
P1023
IP地址 题解:记录点的个数,使用atoi函数将各位转整数
AiLanKeSi
回复 0
|
赞 2
|
浏览 277
#include <iostream> #include <cstdlib> #include <string.h> using namespace std; int main() { char str[10...
四川大学
2020电子信息专硕初试379双非二战经验贴
都忘了
回复 0
|
赞 1
|
浏览 10.7k
写这个经验贴只是希望能将自己两年的考研经验分享给学弟学妹,让你们可以少走点弯路,我还记得我一战成绩出来那晚的心情,就特别希望第二天醒来,发现这只是个梦,然而并不可能。当时决定二战的我总结了很长的失败分析,(正视自己复习出现的问题,列可行方案解决问题,计算二战...
P1240
首字母大写 题解:
Chen沧月有泪
回复 0
|
赞 13
|
浏览 429
#define _CRT_SECURE_NO_WARNINGS #include<stdio.h> #include<string.h> int main() { char s[105]; &...
P1156
质因数个数 题解:C
小王桐学
回复 0
|
赞 3
|
浏览 888
#include <stdio.h> #include <math.h> int isPrimary(int n) { int i; for(i = 2; i <= sqrt(n); i++) if(n % i == 0) break;...
P1217
国名排序 题解:自用笔记(C语言不用库函数)
zx142407789
回复 0
|
赞 3
|
浏览 788
#include<stdio.h> #include<stdlib.h> typedef struct { char name[100]; }country;//用结构体的原因是结构体之间可以赋值 void swap(country* a, coun...
P1253
双向最长不上升子序列
James
回复 0
|
赞 8
|
浏览 10.0k
#include <iostream> #include <algorithm> #include <stdio.h> #include <string.h> using namespace std; const int maxn=10...
备考笔记
旋转矩阵问题,主要是对构建过程的模拟
Chenrui Xu
回复 0
|
赞 0
|
浏览 551
#include <stdio.h> int cnt = 1; // 全局变量,用于填充矩阵的数字 int main() { &nb...
P1476
查找学生信息2 题解:
easymoney
回复 0
|
赞 2
|
浏览 684
#include <stdio.h> #include <algorithm> #include <iostream> #include <map> using namespace std; struct student{  ...
数据结构
【2025年】408计算机统考真题模拟考试 - 第42题答案笔记
Enzo104
回复 0
|
赞 0
|
浏览 290
P1233
利用完全二叉树的性质
shmilyzsc
回复 0
|
赞 3
|
浏览 8.8k
#include <bits/stdc++.h> using namespace std; int main() { int a,b,x; //其父亲节点编号为[n/2] while(cin >> a >> b) { ...
P1542
这是第几天? 题解:求助大佬,为什么按注释掉的部分写只有66%
孙某人
回复 8
|
赞 3
|
浏览 835
#include <iostream> using namespace std; int main(){ /*char a[20]; for(int i=0;i<20;i++) a[i]=0; cin >>a; int yea...
P1704
输出图形 题解:简单循环
RingoCrystal
回复 0
|
赞 4
|
浏览 292
#include <bits/stdc++.h> using namespace std; int main() { int n; while(cin>>n){ int k=1; for(int i...
P1911
反转公约数 题解:
Pstary
回复 0
|
赞 1
|
浏览 756
#include<stdio.h> #include<string.h> #include<stdbool.h> #include<stdlib.h> #include<math.h> #define N 100010 ...
P1003
翻转数的和 题解:暴力
zxjrheaven
回复 0
|
赞 4
|
浏览 230
#include <bits/stdc++.h> using namespace std; int main() { int m,n; int a,b;  ...
P1905
整数排序 题解:
zxd12363
回复 0
|
赞 2
|
浏览 580
#include <bits/stdc++.h> using namespace std; int count(int n) { int count = 0; while (n != 0) &n...
P1053
偷菜时间表 题解:
orderrr
回复 0
|
赞 1
|
浏览 857
/* 思想: 1、将每种菜的用时换算为分钟 2、将提醒时间加到现在的时间上 3、有可能要第二天了,所以小时数应该在24:00时变为0:00 */ #include...
1
2
我要提问
全站热榜
1
无法正确通过题目都是哪些原因造成的?
2
机试如何才能快速提高?
3
题目难点:数学公式不断化解
4
[置顶]计算机考研择校分析【25考研必读】
5
逻辑很简单,但是实现却要小心多多
6
A+B问题 题解:C
7
1017 幂次方 快速幂模板
8
日期 题解:
9
广度优先搜索计算每个人移动到每个位置需要去掉障碍物的最少数目,最后求和的最小值
10
负二进制 题解: