亚洲激情专区-91九色丨porny丨老师-久久久久久久女国产乱让韩-国产精品午夜小视频观看

溫馨提示×

溫馨提示×

您好,登錄后才能下訂單哦!

密碼登錄×
登錄注冊×
其他方式登錄
點擊 登錄注冊 即表示同意《億速云用戶服務條款》

2014 IGT 軟件測試開發工程師筆試(java-B1版)

發布時間:2020-04-10 02:04:14 來源:網絡 閱讀:1080 作者:lolo091 欄目:軟件技術

【IGT】 Paper Test For Campus Recruiting

注:分享出來,僅做個人知識點的查漏補缺以及鞭策自己更加努力地學習!(粗體紅字為鄙人做的答案,可能會有錯誤,還望能有人指出。)

Part 1:

1、which of these is a legal definition of a method named m assuming it throws IOExecption,and returns void .Also assume that the method does not take any arguments.Select the one correct answer.

A void m() throws IOExecption{}

B void m() throw IOExecption{}

C void m(void) throw IOExecption{}

D void m(){}throws IOExecption{}


2、which of the following is legal identifier name in java.

A %abcd

B 1abcd(第一個為數字1)

C package

D _a_long_name

(知識點說明:Java語言規定標識符是以字母、下劃線"_"或美元符號"$"開始,隨后可跟數字、字母、下劃線或美元符號的字符序列,當然不能用關鍵字作為標識符。)


3、what will happen when you attempt to compile and run the following code?

package igt;

public class igt {

public static void main(String[] args){

int i;

switch(i){

case 0:System.out.println(0);

case 1:System.out.println(1);break;

case 2:System.out.println(2);

case 3:System.out.println(3);break;

}

}

}

A 0

B 01

C 0123

D compile error

(知識點說明:關于java變量是否自動初始化問題--成員變量會被初始化,局部變量不會初始化。局部變量如果定義時沒有進行初始化,系統不會自動為其進行初始化,因而編譯時會出錯。如下圖所示:

2014 IGT 軟件測試開發工程師筆試(java-B1版)







4、what will be the output of the program?

public class test_4 {

static class A{

public int x = 10;

public int y = 20;

int f(){

return y;

}

}

static class B extends A{

public int x = 1;

public int y = 30;

int f(){

return y;

}

}

public static void main(String[] args){

A a = new B();

System.out.print(a.x+",");

System.out.println(a.f());

}

}

A 10,20

B 10,30

C 1,20

D 1,30

(實驗得出結果是B,不解中....)


5、what will be the output of the program?

public class test_5 extends Base{

static{

System.out.print("6");

}{

System.out.print("5");

}

public test_5(){

System.out.print("4");

}

public static void main(String[] args){

new test_5();

}

}

class Base{

static{

System.out.print("3");

}{

System.out.print("2");

}

public Base(){

System.out.print("1");

}

}

A 326514

B 361425

C 362154

D 362514
(實驗得出結果是C,不解中....)


Part 2:

6、please decribe the scenarios of using String StringBuffer StringBuilder,and what is the difference between StringBuffer and StringBuilder?


7、please explain the difference between checked exception and runtime exception and the usage of these two kinds of exception.


8、please give an example of self-defined class that could be sorted in Collections.sort() method


9、please list at least three design patterns and its usage in your daily development.


Part 3:

10、please implement a function to find the longest common sub-string of two given string.

for example:

string a: abcdefg12345

string b:cdef234

longest common sub-string:cdef

(字符串匹配問題常考查,需研究透徹!)


--------------------------未解問題,待續。

向AI問一下細節

免責聲明:本站發布的內容(圖片、視頻和文字)以原創、轉載和分享為主,文章觀點不代表本網站立場,如果涉及侵權請聯系站長郵箱:is@yisu.com進行舉報,并提供相關證據,一經查實,將立刻刪除涉嫌侵權內容。

AI

柳河县| 钟山县| 钦州市| 江川县| 平和县| 高邮市| 柘城县| 贵港市| 广元市| 云霄县| 南投市| 兴文县| 吉安县| 凤翔县| 阿坝县| 马鞍山市| 平罗县| 唐河县| 镇远县| 南丰县| 渝北区| 资讯| 襄樊市| 崇州市| 玉溪市| 水富县| 浪卡子县| 平安县| 广宗县| 磐石市| 鄂伦春自治旗| 甘洛县| 万年县| 娱乐| 苏尼特右旗| 无为县| 乐亭县| 万山特区| 安陆市| 安达市| 罗甸县|