
北京理工大学计算机考研
文章平均质量分 73
北京理工大学计算机考研历年上机和面试题目汇总
皮得一1
这个作者很懒,什么都没留下…
展开
-
历年北京理工大学计算机复试
历年北京理工大学复试上机题历年北京理工大学复试专业综合题原创 2020-09-01 13:53:18 · 28616 阅读 · 3 评论 -
历年北京理工大学计算机初试专业课
历年北京理工大学计算机初试专业课资料原创 2018-03-31 13:21:06 · 3491 阅读 · 1 评论 -
2017年北理复试上机题
历年北京理工大学复试上机题题目汇总:http://blog.youkuaiyun.com/u014552756/article/details/785058451、输入身份证号,通过计算比较校验位来判断身份证号是否正确。如,aaaaaayyyymmddxxsp共18位,其中:年份代码yyyy共4位。最后一位p为校验位。校验规则是:(1)对前17位数字的权求和 S=Sum(Ai*Wi),i=0,...,16Ai...原创 2018-03-14 16:31:03 · 12627 阅读 · 2 评论 -
历年北京理工大学复试专业综合题
。原创 2017-11-11 12:56:22 · 26216 阅读 · 3 评论 -
历年北京理工大学复试上机题
历年北京理工大学计算机复试(上机+专业综合):http://blog.youkuaiyun.com/u014552756/article/details/785060722000年北理复试上机题2001年北理复试上机题(A)2001年北理复试上机题(B)2002年北理复试上机题(A)2002年北理复试上机题(B)2003年北理复试上机题2004年北理复试上机题2005年北理复试上机题2006年北理复试上机题2...原创 2017-11-11 12:41:43 · 37445 阅读 · 11 评论 -
根据中缀表达式求出后缀表达式
思路:根据中缀表达式构造二叉树,再后序遍历。#include#includeusing namespace std;//根据中缀表达式求出后缀表达式typedef struct node{ string v; node *l; node *r;};void In2T(string In,node *&T){ if(T==NULL) {原创 2017-03-08 15:18:32 · 1508 阅读 · 0 评论 -
2016年北理复试上机题
1、输入字符串,输出字符串中包含的数字,比如 2.3ABC0-2.3 输出 2.3 0 -2.3。注意一些特殊的情况如+004.500值为+4.5。#include using namespace std;int main(){ string str,s[105],ss; getline(cin,str); str[str.length()]='A';原创 2017-03-08 00:00:03 · 10847 阅读 · 3 评论 -
2000年北理复试上机题
1、输入任意 4 个字符(如:abcd),并按反序输出(如:dcba)。#include #includeusing namespace std;int main(){ string s; int i; cout<<"请输入字符串:"<<endl; cin>>s; cout<<"反序输出:"<<endl; for(i=s.length(原创 2017-02-26 19:45:48 · 5965 阅读 · 2 评论 -
2001年北理复试上机题(B)
1、请输入高度 h,输入一个高为 h,上底边长为 h的等腰梯形(例如 h=4,图形如下)。**** ****** ******** **********#includeusing namespace std;int main(){ int h,i,j; cout<<"请输入高度:"<<endl; cin>>h;原创 2017-02-26 19:17:22 · 2315 阅读 · 2 评论 -
2001年北理复试上机题(A)
1、编写程序,计算下列分段函数 y=f(x)的值。y= -x+2,50y=2-1.5(x-3)(x-3),2y=x/2-1.5,4#include#includeusing namespace std;int main(){ double x,y=0; cout<<"请输入x的值:"<<endl; cin>>x; if(x>=0&&x<2)原创 2017-02-26 18:51:02 · 3685 阅读 · 2 评论 -
2002年北理复试上机题(B)
1、打印所有不超过 n(n)的,其平方具有对称性质的数。如 11*11=121。#include#includeusing namespace std;int main(){ int a,s1,s2,i,j,b[10]; cout<<"符合条件的数有:"<<endl; for(a=1; a<=256; a++) { i=0;原创 2017-02-26 15:51:47 · 2114 阅读 · 0 评论 -
2002年北理复试上机题(A)
1、某人有 8 角的邮票 5 张,1 元的邮票 4 张,1元 8 角的邮票 6 张,用这些邮票中的一张或若干张可以得到多少种不同的邮资?参考链接:set用法#include#includeusing namespace std;int main(){ double a,b,c; int i=1; set se; cout<<"可以组成的钞票额度为原创 2017-02-26 15:31:06 · 2613 阅读 · 5 评论 -
2003年北理复试上机题
历年北京理工大学复试上机题题目汇总:http://blog.youkuaiyun.com/u014552756/article/details/785058451、输入球的中心点和球上某一点的坐标,计算球半径和体积。#include<iostream>#include<math.h>using namespace std;double co...原创 2017-02-26 13:40:48 · 2542 阅读 · 2 评论 -
2004年北理复试上机题
1、建立一个角类,在这个类中重载减号运算符,并实现求出角度的正弦值的函数。2、建 立一 个 求 一 元二 次 方 程 解的 类( a*x^2+b*x+c=0 ),输入系数 a,b,c 的值后打印出这个方程的解来,也比较简单。 需要注意的是系数 a 不能为零以及方程有无解,单解还是双解的情况。3、实现一个多项式的类(a+b*x+c*x^2+d*x^3+...+),要求输入该多项式的系数和 x原创 2017-02-25 22:17:47 · 2583 阅读 · 3 评论 -
2005年北理复试上机题
1、给定一个程序,关于字符串的,要求输入并调试,说出此程序的意图。意图是按字母顺序对两个字符串比较排序。第二问要求用尽可能少的语句对该程序进行修改,使其能够对两个字符串比较长度排序。2、编写一个日期类,要求按 xxxx-xx-xx 的格式输出日期,实现加一天的操作,不考虑闰年问题,所有月份设为 30 天。本题黑盒测试时,输入 2004 年 3 月 20日,得到加一天后时间为 2004-原创 2017-02-24 15:55:39 · 2419 阅读 · 3 评论 -
2006年北理复试上机题
1、写一个程序判断字符串中数字的位置(不限制使用面向对象编程)例如:输入 a3b4c5,输出 2 4 6 。2、写一个类,能接受int 型的变量,接收变量后能存储原变量(譬如 12345)和其反向变量(54321) ,最多处理数量为 10 个,当输入达到 10 个或者输入变量为 0 的时候停止。并且在类销毁前输出存储的所有变量。 例如:输入:12345,2234,0输出:12345原创 2017-02-24 10:59:00 · 2456 阅读 · 4 评论 -
2007年北理复试上机题
1、一个小球,从高为H的地方下落,下落弹地之后弹起高度为下落时的一半,比如第一次弹起高度为H/2,如此反复,计算从小球H高度下落到n次弹地往返的总路程。要求:(1)用递归的方法实现。(2)输入H和n,输出结果。(3)注意程序的健壮性。(4)可以用C/C++实现。2、创建一个CPoint类,代表平面直角坐标系中的点,创建构造函数和运算符重载函数,运算符重载为类重载(非友元重载),可以实现计算原创 2017-02-24 00:32:25 · 2703 阅读 · 1 评论 -
2008年北理复试上机题
1、存储一组姓名,如Apple,Tom,Green,Jack要求能排序、按字母顺序插入、并显示。#include #include #include using namespace std;int main(){ string s; vector st; cout<<"请输入单词,以00结束:"<<endl; vector::iterator i;原创 2017-02-23 22:21:21 · 3011 阅读 · 4 评论 -
2009年北理复试上机题
1、请输入字符串,最多输入4个字符串,要求后输入的字符串排在前面,例如:输入:EricZ输出:1=EricZ输入:David输出:1=David 2=EricZ参考链接:deque用法#include #include #include #include using namespace std;int main(){ deque dequ; st原创 2017-02-23 11:07:07 · 3514 阅读 · 0 评论 -
2010年北理复试上机题
1、输入一串整数,输入指令。要求:(1)输入a t,在这串整数后添加整数t。(2)输入c\m\n,用n替换m。(3)输入d t,删除t。(4)输入s排序。#include #include #include #include #include using namespace std;int main(){ vector arr; int a; char原创 2017-02-23 00:22:55 · 4149 阅读 · 1 评论 -
2011年北理复试上机题
#include #include #include using namespace std;int main(){ set s; map m; string str; while(cin>>str) { s.insert(str); } set::iterator it; for(it=s.begin(原创 2017-02-17 23:59:40 · 4133 阅读 · 2 评论 -
2012年北理复试上机题
#include #include using namespace std;int main(){ int a[15]; for(int i=0; i<10; i++) cin>>a[i]; sort(a,a+10); for(int i=0; i<9; i++) cout<<a[i]<<","; cout<<a[原创 2017-02-17 20:08:57 · 4284 阅读 · 2 评论 -
2013年北理复试上机题
#include using namespace std;int gcd(int a,int b){ int t; if(a<b) { t=a; a=b; b=t; } while(t=a%b) { a=b; b=t; } return b;}原创 2017-02-17 15:10:37 · 5134 阅读 · 4 评论 -
2014年北理复试上机题
#include using namespace std;int main(){ int n=-1,a[1005],h=0,t=0; while(1) { cout<<"输入:"; cin>>n; if(n==0) return 0; if(t-h==0) {原创 2017-02-17 11:02:27 · 5360 阅读 · 0 评论