栏目分类:
子分类:
返回
名师互学网用户登录
快速导航关闭
当前搜索
当前分类
子分类
实用工具
热门搜索
名师互学网 > IT > 面试经验 > Java面试题

金蝶技术有限公司Java面试题

Java面试题 更新时间: 发布时间: IT归档 最新发布 模块sitemap 名妆网 法律咨询 聚返吧 英语巴士网 伯小乐 网商动力

金蝶技术有限公司Java面试题

一、100,100,102,106,112,120 ,130
0,2,4,6,8

x-8 = 2
x = 10

n-120 = x
n = 130

二、有两个数组A,B,B数组中的元素包含在A数组中,请写一段代码把A数组中B没有的元素放到C数组中。
int [] A = new int[]{0,1,2,3,4,5,6,7,8,9};
int [] B = new int[]{2,4,6,8};
int [] C =new int[A.length-B.length];
int count = 0;
for(int i = 0;i < A.length;i++){
boolean bool = true;
for(int j = 0;j < B.length;j++){
if(A[i] == B[j]){
bool = false;
}
}
if(bool){
C[count] = A[i];
count++;
}
}

for(int i = 0;i < C.length;i++){
System.out.println(C[i]);
}
三、假如数组中都是数字,而且已经按大小排序,请写一段代码最快效率把上一题的元素放到C数组中。
int [] num = new int[]{0,1,2,3,4,5,6,7,8,9};
int [] temp = new int[num.length];
temp = num;
for(int i = 0;i < temp.length;i++){
System.out.println(temp[i]);
}
四、写一个对数组的排序的代码段。
int [] num = new int[]{4,6,2,7,1,3,9,8,5,0};
for(int i = 0;i < num.length;i++){
for(int j =0;j < num.length;j++){
if(num[i] < num[j]){
int temp = 0;
temp = num[i];
num[i] = num[j];
num[j] = temp;
}
}
}

for(int i = 0;i < num.length;i++){
System.out.println(num[i]);
}
五、jsp与servlet的区别?它们的生命周期?jsp或servlet的转发(forword),包含(include),重定向(Redirect)的区别?
六、MVC的概念?你用过哪些基于MVC的框架?

转载请注明:文章转载自 www.mshxw.com
本文地址:https://www.mshxw.com/it/264012.html
我们一直用心在做
关于我们 文章归档 网站地图 联系我们

版权所有 (c)2021-2022 MSHXW.COM

ICP备案号:晋ICP备2021003244-6号