聯(lián)系客服微信掃一掃關(guān)注公眾號后聯(lián)系客服
掃碼練習(xí)微信掃碼免費搜題
  • 首頁

  • 題庫

  • 網(wǎng)課

  • 在線???/h3>

  • 桌面端

登錄
  • 搜標題
  • 搜題干
  • 搜選項
單項選擇題

public class Threads3 implements Runnable { 
public void run() { 
System.out.print(”running”); 
} 
public static void main(String[] args) { 
Thread t = new Thread(new Threads3()); 
t.run(); 
t.run(); 
t.start(); 
} 
} 
What is the result?() 

A. Compilation fails.
B. An exception is thrown at runtime.
C. The code executes and prints “running”.
D. The code executes and prints “runningrunning”.
E. The code executes and prints “runningrunningrunning”.

題目列表

你可能感興趣的試題

  • 多項選擇題

    Which two code fragments will execute the method doStuff() in a separate thread?()

    A. new Thread() { public void run() { doStuff(); } }
    B. new Thread() { public void start() { doStuff(); } }
    C. new Thread() { public void start() { doStuff(); } } .run();
    D. new Thread() { public void run() { doStuff(); } } .start();
    E. new Thread(new Runnable() { public void run() { doStuff(); } } ).run();
    F. new Thread(new Runnable() { public void run() { doStuff(); } }).start();

  • 單項選擇題

    12. String csv = “Sue,5,true,3”; 
    13. Scanner scanner = new Scanner( csv); 
    14. scanner.useDelimiter(”,”); 
    15. int age = scanner.nextInt(); 
    What is the result?() 

    A. Compilation fails.
    B. After line 15, the value of age is 5.
    C. After line 15, the value of age is 3.
    D. An exception is thrown at runtime.

掃碼聯(lián)系掃碼聯(lián)系在線客服
反饋使用問題
掃碼練習(xí)掃碼使用找答案小程序
手機搜題/刷題/上網(wǎng)課

版權(quán)所有?考試資料網(wǎng)(ppkao.com) 長沙求知信息技術(shù)有限公司 All Rights Reserved

湘公網(wǎng)安備 43010202000353號備案號: 湘ICP備14005140號-2

經(jīng)營許可證號 : 湘B2-20140064

  • 聯(lián)系客服
  • 小程序
  • 桌面端下載
  • 回到頂部

感谢您访问我们的网站,您可能还对以下资源感兴趣:

国产黄色视屏

      <mark id="aorvc"></mark>
        <ol id="aorvc"></ol>