A.Applet的默认布局管理器是FlowLayout
B.JApplet中增加构件是加到JApplet的内容面板上,不是直接加到JApplet中
C.JApplet的内容面板的默认布局管理器是BorderLayout
D.JApplet的内容面板的默认布局管理器是FlowLayout
单选题 | 下列对队列的叙述正确的是 | 查看答案 |
单选题 | 请阅读下面程序 public class ForLoopStatement { public static void main(String[] args) { int i,j; for(i=1;i<5;i++){ \TAB //i循环 for(j=1;j<=i;j++) \TAB //j循环 System.out.print(i+"×"+j+"="+i*j+" "); System.out.println(); } } } 程序完成后,i循环和j循环执行的次数分别是 |
查看答案 |
单选题 | 下列叙述中,错误的是 | 查看答案 |
单选题 | 请阅读下面程序 public class OperatorsAndExpressions { void residual(){ int i=100,j=30; float m=563.5f,n=4.0f; System.out.println(i%j); System.out.println(m%n); } public static void main(String args[]){ OperatorsAndExpressions OperAndExp=new OperatorsAndExpressions(); //取模运算符在整数和浮点数中的应用 OperAndExp.residual(); } } 程序运行结果是 |
查看答案 |
单选题 | 请阅读下面程序 import java.io.*; public class ExceptionCatch{ public static void main(String args[]){ try{ FileInputStream fis=new FileInputStream("text"); System.out.println("content of text is:"); } catch(FileNotFoundException e){ System.out.println(e); System.out.println("message:"+e.getMessage()); e.printStackTrace(System.out); }____________________{ System.out.println(e); } } } 为保证程序正确运行,程序中下划线处的语句应是 |
查看答案 |
单选题 | 请阅读下面程序 public class ExampleStringBuffer{ public static void main(String[] args){ StringBuffer sb=new StringBuffer ("test"); System.out.println("buffer ="+sb); System.out.println("length ="+sb.length()); } } 程序运行结果中在"length="后输出的值是 |
查看答案 |
单选题 | 下列叙述中,错误的是 | 查看答案 |
单选题 | 请阅读下面程序 import java.io.*; public class TypeTransition{ public static void main(String args[]){ char a = 'a'; int i = 100; long y = 456L; int aa = a + i; long yy = y-aa; System.out.print("aa = "+aa); System.out.print("yy = "+yy); } } 程序运行结果是 |
查看答案 |
单选题 | 下列叙述中,错误的是 | 查看答案 |
单选题 | Java对I/O访问所提供的同步处理机制是 | 查看答案 |
单选题 | Java语言与C++语言相比,最突出的特点是 | 查看答案 |
单选题 | 对下列二叉树 进行前序遍历的结果是 |
查看答案 |
单选题 | 在定制Applet的绘图功能时,应该使用的方法是 | 查看答案 |
单选题 | 下列叙述中,错误的是 | 查看答案 |
单选题 | 在下列Java语言的包中,提供图形界面构件的包是 | 查看答案 |
单选题 | 下列叙述中正确的是 | 查看答案 |
单选题 | 在E-R图中,用来表示实体之间联系的图形是 | 查看答案 |
单选题 | 请阅读下面程序 public class ThreadTest { public static void main(String args[ ]) throws Exception{ int i=0; Hello t = new Hello( ); __________________; while( true){ System.out.println("Good Morning"+i++); if (i == 2 && t.isAlive()){ System.out.println("Main waiting for Hello!"); t.join(); //等待t运行结束 } if (i==5) break ;} } } class Hello extends Thread{ int i ; public void run( ){ while( true){ System.out.println("Hello"+i++); if (i==5) break ;}}} 为使该程序正确执行,下划线处的语句应是 |
查看答案 |
单选题 | 下列叙述中错误的是 | 查看答案 |
单选题 | 下列叙述中,错误的是 | 查看答案 |