freepeople性欧美熟妇, 色戒完整版无删减158分钟hd, 无码精品国产vα在线观看DVD, 丰满少妇伦精品无码专区在线观看,艾栗栗与纹身男宾馆3p50分钟,国产AV片在线观看,黑人与美女高潮,18岁女RAPPERDISSSUBS,国产手机在机看影片

正文內(nèi)容

java題庫(kù)—175道選擇題(已修改)

2025-04-05 04:57 本頁(yè)面
 

【正文】 《Java程序設(shè)計(jì)》理論題庫(kù)—選擇題(單選175題),此類繼承了List接口,下列哪個(gè)方法是正確的 ? BA、 ArrayList myList=new Object(); B、 List myList=new ArrayList(); C、 ArrayList myList=new List(); D、 List myList=new List();()方法使用哪種類型的參數(shù)? AA、 Graphics B、 Graphics2D C、 String D、 Color DA、 byte=128。 //byte取值到127B、 Boolean=null。 C、 long l=0xfffL。 D、 double=。 Bpublic class Example{   String str=new String(good)。   char[]ch={39。a39。,39。b39。,39。c39。}。   public static void main(String args[]){     Example ex=new Example()。     (,)。     (+ and )。     ()。   }   public void change(String str,char ch[]){     str=test ok。     ch[0]=39。g39。   } } A、 good and abc B、 good and gbc C、test ok and abc D、 test ok and gbc , 會(huì)產(chǎn)生什么結(jié)果 C Dpublic class X extends Thread implements Runable{  public void run(){   (this is run())。  }  public static void main(String args[])  {   Thread t=new Thread(new X())。   ()。  } } A、 第一行會(huì)產(chǎn)生編譯錯(cuò)誤 B、 第六行會(huì)產(chǎn)生編譯錯(cuò)誤 C、 第六行會(huì)產(chǎn)生運(yùn)行錯(cuò)誤 D、 程序會(huì)運(yùn)行和啟動(dòng) 文件中讀出第10個(gè)字節(jié)到變量C中,下列哪個(gè)方法適合? AA、 FileInputStream in=new FileInputStream()。 (9)。 int c=()。 B、 FileInputStream in=new FileInputStream()。 (10)。 int c=()。 C、 FileInputStream in=new FileInputStream()。 int c=()。 D、 RandomAccessFile in=new RandomAccessFile()。 (9)。 int c=()。 ,哪種布局管理器的容器中的組件大小不隨容器大小的變化而改變? BA、 CardLayout B、 FlowLayout C、 BorderLayout D、 GridLayout : public class Person{   static int arr[] = new int[10]。  public static void main(String a[])   {    (arr[1])。   } } 那個(gè)語(yǔ)句是正確的? CA、 編譯時(shí)將產(chǎn)生錯(cuò)誤; B、 編譯時(shí)正確,運(yùn)行時(shí)將產(chǎn)生錯(cuò)誤; C 、輸出零; D、 輸出空。 ? BA、 transient B synchronized C serialize D static ? BA、 程序員必須創(chuàng)建一個(gè)線程來(lái)釋放內(nèi)存; B、 內(nèi)存回收程序負(fù)責(zé)釋放無(wú)用內(nèi)存 C、內(nèi)存回收程序允許程序員直接釋放內(nèi)存 D、內(nèi)存回收程序可以在指定的時(shí)間釋放內(nèi)存對(duì)象 : C1) public void modify() { 2) int I, j, k。 3) I = 100。 4) while ( I 0 ) { 5) j = I * 2。 6) ( The value of j is + j )。 7) k = k + 1。 8) I。 9) } 10} } A、 line 4 B、 line 6 C、 line 7 D、 line 8, 變量值保持為常量100,用簡(jiǎn)短語(yǔ)句定義這個(gè)變量。 DA、 public int MAX_LENGTH=100。 B、 final int MAX_LENGTH=100。 C、 final public int MAX_LENGTH=100。 D、 public final int MAX_LENGTH=100. :  1) class Parent {   2} private String name。   3} public Parent(){}   4} }   5) public class Child extends Parent {   6} private String department。   7} public Child() {}   8} public String getValue(){ return name。 }   9} public static void main(String arg[]) {   10} Parent p = new Parent()。   11} }   12} }   那些行將引起錯(cuò)誤? DA、 第3行 B、 第6行 C、 第7行 D、 第8行;    Person p。    Teacher t。    Student s。    //p, t and s are all nonnull.    if(t instanceof Person) { s = (Student)t。 }   最后一句語(yǔ)句的結(jié)果是: B CA、 將構(gòu)造一個(gè)Student對(duì)象; B、 表達(dá)式是合法的; C、 表達(dá)式是錯(cuò)誤的; D、 編譯時(shí)正確,但運(yùn)行時(shí)錯(cuò)誤。   1) public class Test {   2) int m, n。   3) public Test() {}   4) public Test(int a) { m=a。 }   5) public static void main(String arg[]) {   6) Test t1,t2。   7) int j,k。   8) j=0。 k=0。   9) t1=new Test()。   10) t2=new Test(j,k)。   11) }   12) }  哪行將引起一個(gè)編譯時(shí)錯(cuò)誤? DA、 line 3 B、 line 5 C、 line 6 D、 line 10 :   1) class Person {   2) public void printValue(int i, int j) {//... }   3) public void printValue(int i){//... }  4) }   5) public class Teacher extends Person {   6) public void printValue() {//... }   7) public void printValue(int i) {//...}   8) public static void main(String args[]){   9) Person t = new Teacher()。   10) (10)。   11) }   第10行語(yǔ)句將調(diào)用哪行語(yǔ)句?? DA、 line 2 B、 line 3 C、 line 6 D、 line 7? CA、 transient B、 finally C、 throw D、 static ()方法的返回類型是: BA、 int B、 void C、 boolean D、 static ? DA、 B、 C、 D、 :   public class Parent {    public int addValue( int a, int b) {      int s。      s = a+b。      return s。    }   }   class Child extends Parent {   }  下述哪些方法可以加入類Child? CA、 int addValue( int a, int b ){// do something...} B、 public void addValue (int a, int b ){// do something...} C、 public int addValue( int a ){// do something...} D、 public int addValue( int a, int b )throws MyException {//do something...} :   public class test{    static int a[] = new a[10]。    public static void main(String args[]) {     (a[10])。    }   } 那個(gè)選項(xiàng)是正確的? AA、 編譯時(shí)將產(chǎn)生錯(cuò)誤; B、 編譯時(shí)正確,運(yùn)行時(shí)將產(chǎn)生錯(cuò)誤; C、 輸出零; D、 輸出空。 ? BA、 public main(String args[]) B、 public static void main(String args[]) C、 private static void main(S
點(diǎn)擊復(fù)制文檔內(nèi)容
試題試卷相關(guān)推薦
文庫(kù)吧 www.dybbs8.com
公安備案圖鄂ICP備17016276號(hào)-1