公眾號(hào):mywangxiao
及時(shí)發(fā)布考試資訊
分享考試技巧、復(fù)習(xí)經(jīng)驗(yàn)
新浪微博 @wangxiaocn關(guān)注微博
聯(lián)系方式 400-18-8000
question 16)
which of the following statements are true?
1) methods cannot be overriden to be more private
2) static methods cannot be overloaded
3) private methods cannot be overloaded
4) an overloaded method cannot throw exceptions not checked in the base class
question 17)
what will happen if you attempt to compile and run the following code?
class base {}class sub extends base {}class sub2 extends base {}public class cex{ public static void main(string argv[]){ base b=new base(); sub s=(sub) b; }}
1) compile and run without error
2) compile time exception
3) runtime exception
question 18)
which of the following statements are true?
1) system.out.println( -1 >>> 2);will output a result larger than 10
2) system.out.println( -1 >>> 2); will output a positive number
3) system.out.println( 2 >> 1); will output the number 1
4) system.out.println( 1 <<< 2); will output the number
編輯推薦:
JAVA認(rèn)證考試報(bào)考指南 / 更多JAVA考試模擬試題
(責(zé)任編輯:zyc)