【阿摩網站-置頂欄顏色票選問卷】只要填寫就能獲得500Y,結束時間 2024/04/25 11:59:59。 前往查看

计算机等级考试— 二级—《 JAVA 》題庫下載題庫

上一題
34)下列程序的功能是在监控台上每隔一秒钟显示一个字符串“Hello”,能够填写在程序中下划线位 置,使程序完整并能正确运行的语句是 public class Test implements Runnable{ public static void main(String args[]){ Test t=new Test(); Thread tt=new Thread(t); tt.start(); } public void run(){ for(;;){ try{ ; }catch( e){} System.put.println("Hello"); } } }
(A)sleep(1000) InterruptedException
(B)sleep(1000) InterruptedException
(C)Thread.sleep(1000) RuntimeException
(D)Thread.sleep(1000) InterruptedException


34)下列程序的功能是在监控台上每隔一秒钟显示一个字符串“Hello”,能够填写..-阿摩線上測驗