首页
DreamJudge
院校信息
专业题库
模拟考试
机试真题
上岸课程
兑换中心
登录
注册
上岸
A1120161820
这个人很懒,什么都没有写。。。
关注
发消息
文章
0
题解
84
发帖
0
笔记
0
Ta的粉丝
408
关注数
2
粉丝数
408
获赞数
124
阅读数
898525
细菌的繁殖(c++)
本题可以当成一个数学题来做。 将第i天细菌最中间一行的数目记作数列a[i]:a[1] = 1, a[2] = 5, a[3] = 13; 可以得到a[i] = 2*i - 1 第i天细菌总数s[i] = 2*(a[1]+a[2]+...+a[i-1]) + a[i] = 2*...
P1033
2020年3月24日 15:33
回复 1
|
赞 3
|
浏览 13.5k
偷菜时间表(c++)
输入采用scanf("%d:%d", &time.hour, &time.minute)会比较省事 #include<iostream> #include<cstdio> #include<vector...
P1053
2020年7月13日 09:55
回复 1
|
赞 1
|
浏览 10.8k
日期累加(c++)
#include<iostream> #include<cstdio> using namespace std; int days[] = {0, 31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31}; bool i...
P1446
2020年3月8日 10:06
回复 1
|
赞 0
|
浏览 12.1k
日期类(c++)
#include<iostream> #include<cstdio> using namespace std; int days[] = {0, 31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31}; bool e...
P1437
2020年3月6日 16:24
回复 2
|
赞 1
|
浏览 11.2k
杨辉三角形(c++)
#include<iostream> using namespace std; int main() { int tr[21][21]; for (int i = 1; i <= 20; i++) { for (int j = 1; j <= 2...
P1062
2020年7月24日 09:46
回复 0
|
赞 4
|
浏览 13.4k
单向公路
这就是一个搜索问题,dfs或者bfs均可 #include<iostream> #include<cstring> using namespace std; bool stat[1001][1001]; bool visited[1001]; v...
P1061
2020年7月24日 09:30
回复 0
|
赞 0
|
浏览 10.7k
求组合数(c++)
#include<iostream> using namespace std; int comb(int n, int r) { if (r == 0) return 1; else if (r == 1) return n; else re...
P1058
2020年7月19日 10:07
回复 0
|
赞 2
|
浏览 9.5k
数字模式的识别(c++)
看到这题,首先想到的是,利用数组存所有可能的数字,数组下标对应数字,元素值对应其出现的次数。但题目中|input_number| <= 2000000,所以这样做带来的空间开销太大了。 于是,换了一种思路,用数组存下所有的数,然后进行升序排列,记录下每个元素出现的次数,并不断更新模...
P1057
2020年7月19日 09:53
回复 0
|
赞 4
|
浏览 10.0k
沙漠储油点(c++)
参考:https://blog.csdn.net/daoqin121/article/details/39321481 首先明确一点:储油点的油都是卡车自己从起点一个个运过来的,即:卡车首先从起点跑若干趟将油运到第一个储油点,然后依次跑若干趟将油运往下一个储油点,最后距离终点500km时...
P1056
2020年7月18日 11:29
回复 0
|
赞 3
|
浏览 11.0k
矩阵相乘
遍历就完事了 #include<iostream> using namespace std; int main() { int a[3][3], b[3][3], c[3][3]; for (int i = 0; i < 3; i++) {...
P1055
2020年7月14日 10:05
回复 0
|
赞 1
|
浏览 9.3k
塑身菜单(c++)
注意:最后是按热量从小到大进行输出 #include<iostream> #include<string> #include<vector> #include<algorithm> using namespace std; s...
P1054
2020年7月14日 09:55
回复 0
|
赞 8
|
浏览 9.4k
学生成绩管理(c++)
注意输入输出格式 #include<iostream> #include<cstdio> #include<vector> using namespace std; typedef struct Node{ string sno; ...
P1052
2020年7月13日 09:32
回复 0
|
赞 0
|
浏览 9.3k
击鼓传花(c++)
按照题意,这是一个循环链表问题,先建链表,再循环出链表 #include<iostream> #include<cstdlib> using namespace std; typedef struct Node{ int number; stru...
P1018
2020年3月21日 09:08
回复 0
|
赞 0
|
浏览 17.0k
字母频率(c++)
注意:最多的字符可能不止一个 #include<iostream> #include<cstring> using namespace std; const int M = 1024; int main() { char line[M]; c...
P1019
2020年3月21日 09:41
回复 0
|
赞 0
|
浏览 11.6k
最长连续因子(c++)
细心点 #include<iostream> #include<vector> using namespace std; int main() { int num; cin >> num; vector<int> f...
P1020
2020年3月21日 10:48
回复 0
|
赞 0
|
浏览 12.0k
复数(c++)
注意:输入的时候接收+或*,如果用char型,应首先去除数字后面的空格 #include<iostream> #include<cstdio> using namespace std; int main() { double a1, b1, a2,...
P1021
2020年3月22日 09:17
回复 0
|
赞 1
|
浏览 10.7k
删除最大最小数(c++)
注意特殊情况: 输入: 5 5 5 5 5 5 输出: 5 5 5 代码: #include<iostream> using namespace std; int main() { int num[105]; in...
P1022
2020年3月22日 09:42
回复 0
|
赞 4
|
浏览 10.9k
IP地址(c++)
注意输出格式:十六进制不足两位要补零 #include<iostream> #include<cstring> #include<cstdlib> using namespace std; const int M = 1024; int ...
P1023
2020年3月22日 10:15
回复 0
|
赞 0
|
浏览 11.8k
二元组整数(c++)
特殊情况: 输入: 5 2 1 3 1 2 输出: (1,1) (1,2) (1,3) (2,1) (2,2) (2,3) (3,1) (3,2) 代码: #include<iostream> #include&...
P1024
2020年3月23日 09:48
回复 0
|
赞 1
|
浏览 13.9k
链表合并(c++)
#include<iostream> using namespace std; typedef struct Node{ int number; struct Node* next; }LNode; int main() { int s1, s2, x; ...
P1025
2020年3月23日 10:18
回复 0
|
赞 0
|
浏览 12.2k
1
2
3
...
5
本科学校:北京理工大学
目标学校:北京理工大学
点此申请N诺身份认证
获得 noobdream 认证,享受多重认证福利!