亚洲精品成人18久久久久_日韩欧美色_江苏极品身材白嫩少妇自拍_曰本人做爰大片免费观看一老师_久草视频网_最近中文字幕MV高清在线视频

首頁 > 考試輔導(dǎo) > 計算機考試 > JAVA認(rèn)證 > JAVA認(rèn)證試題集錦 > SUN認(rèn)證Java2程序員考試(SCJP) 試題解析(3)

SUN認(rèn)證Java2程序員考試(SCJP) 試題解析(3)

what happens when you try to compile and run the following application? choose all correct options.   
1. public class z {   
2. public static void main(string[] args) {   
3. new z();   
4. }   
5.   
6. z() {   
7. z alias1 = this;   
8. z alias2 = this;   
9. synchronized(alias1) {   
10. try {   
11. alias2.wait();   
12. system.out.println(“done waiting”);   
13. }   
14. catch (interruptedexception e) {   
15. system.out.println(“interr   
upted”);   
16. }   
17. catch (exception e) {   
18. system.out.println(“other exception”);   
19. }   
20. finally {   
21. system.out.println   
(“finally”);   
22. }   
23. }   
24. system.out.println(“all done”);   
25. }   
26. }   
a. the application compiles but doesn’t print anything.   
b. the application compiles and print “done waiting”   
c. the application compiles and print “finally”   
d. the application compiles and print “all done”   
e. the application compiles and print “interrupted”   
解答:a   
  點評:在java中,每一個對象都有鎖。任何時候,該鎖都至多由一個線what happens when you try to compile and run the following application? choose all correct options.   
1. public class z {   
2. public static void main(string[] args) {   
3. new z();   
4. }   
5.   
6. z() {   
7. z alias1 = this;   
8. z alias2 = this;   
9. synchronized(alias1) {   
10. try {   
11. alias2.wait();   
12. system.out.println(“done waiting”);   
13. }   
14. catch (interruptedexception e) {   
15. system.out.println(“interr   
upted”);   
16. }   
17. catch (exception e) {   
18. system.out.println(“other exception”);   
19. }   
20. finally {   
21. system.out.println   
(“finally”);   
22. }   
23. }   
24. system.out.println(“all done”);   
25. }   
26. }   
a. the application compiles but doesn’t print anything.   
b. the application compiles and print “done waiting”   
c. the application compiles and print “finally”   
d. the application compiles and print “all done”   
e. the application compiles and print “interrupted”   
解答:a   
  點評:在java中,每一個對象都有鎖。任何時候,該鎖都至多由一個線ent(te),注冊的listener將不會被喚醒。   

scjp考試中的幾點注意:   

● 深刻理解面向?qū)ο蟮乃枷?nbsp;  
  java是一種純粹的面向?qū)ο蟮某绦蛟O(shè)計語言。在正式使用java做開發(fā)之前,必須將我們的思維方式轉(zhuǎn)入一個徹底的面向?qū)ο蟮氖澜纭W霾坏竭@一點,就無法體會java語言的精髓,寫不出地道的java程序。當(dāng)然,你也無法徹底理解java中的基本概念和他們之間的聯(lián)系與區(qū)別,如例題3、例題5。你可以學(xué)到j(luò)ava的語法規(guī)則,卻不能看到j(luò)ava的靈魂。   

● 對概念細(xì)節(jié)的精確把握   
  通過例題我們可以看到,scjp的考察點相當(dāng)細(xì)致。如例題1、2、4、7、8。所以只有對java的概念、語法、規(guī)則了然于心,才能在考場上應(yīng)對自如。   

● 適量的練習(xí)   
  程序設(shè)計是一項實踐性很強的技術(shù)。只有上機實踐,才能使課本中的理論、頭腦中的思想通過你的雙手成為一行行代碼,完成規(guī)定的目標(biāo)。雖然scjp考試不考操作與編程,但有大量的程序閱讀,如例題3、4、9、10。如果你自己寫過許多代碼的話,這種題就是小菜一碟。   

● 廣泛的交流   
  善于交流是優(yōu)秀程序員必備的技能,也是你解決疑難,提高水平的捷徑。國內(nèi)外有很多與java認(rèn)證相關(guān)的優(yōu)秀網(wǎng)站和論壇,都是學(xué)習(xí)java的寶庫。同時,一些很棒的模考軟件,如jxam、jtest、 javacert等,以及著名的模考題如marcusgreen的三套題均可以找到。
主站蜘蛛池模板: 国产亚洲综合专区在线在线观看 | 国产三级精品三级男人的天堂 | 色综综合| 怡春院免费视频 | 韩国一级毛片 | 爆乳女仆高潮在线观看 | 欧美美乳视频网站在线观看 | 亚洲日韩精品射精日 | 一级片欧美日韩 | 一级毛片性色一区二区视频在线 | 九九九热精品 | 岛国免费av | 久久成人在线观看 | 国产成人精品久久亚洲高清不卡 | 日本高清无卡码一区二区久久 | 超薄肉色丝袜一二三四区 | 日韩精品无码一二区A片换脸 | 91精品国产麻豆 | av狼友永久免费网址观看 | 国产日本久久 | av免费播放网站 | chinese白浆高潮videos | 在线视频观看成人 | 国产精品久久久久久久久久综合 | 亚洲人成网7777777国产 | 国产一级淫免费播放m | 国产精品禁久久精品 | 日韩黄色碟片 | 黄色大片a级 | 成人免费福利 | 18禁无遮挡啪啪无码网站 | 日日噜噜噜夜夜爽爽狠狠小说 | 国产精品久久久久久久稀缺资源 | av无线看| 色678黄网全部免费 国产精彩视频 | 国产精品久久久久久久久免费桃花 | 亚洲精品国产精品国自 | 91精品国产欧美一区二区 | 放个毛片看看 | 精品色999| 国产户外野战AV一级 |