A.都属于Map接口的类
B.Hashtable 类不是同步的,HashMap类是同步的
C.Hashtable 类不允许 null 键和 null 值
D.HashMap 类允许null 键和null 值
您可能感兴趣的试卷
你可能感兴趣的试题
A.Error表示系统级的错误
B.Error表示程序不必处理的异常
C.Exception表示需要捕捉的异常
D.Exception表示需要程序进行处理的异常
研究下面的Java代码:
public class testException{
public static void main(String args[]){
int a[]={0,1,2,3,4};
int sum=0;
try{
for(int i=1;i<6;i++)
sum=sum+a[i];
System.out.println("sum="+sum);
}
catch(ArrayIndexOutOfBoundsException ){
System.out.println("数组越界"); }
finally{ System.out.println("程序结束");} } }
输出结果将是()。
A.10 数组越界 程序结束
B.10 程序结束
C.数组越界 程序结束
D.程序结束
编译如下Java程序片断:
class test{
int count = 9;
public void a(){ int count=10;
System.out.println("count 1 =" + count); }
public void count(){
System.out.println("count 2 =" + count); }
public static void main(String args[]){
test t=new test();
t.a(); t.count();
} }
结果将()。
A.不能通过编译
B.输出: count 1 = 10 count 2 = 9
C.输出: count 1 = 9 count 2 = 9
A.NullpointerException
B.ArithmeticExceptioin
C.ArrayIndexOutOfBoundsException
D.SecurityManager
A.button.enableActionEvents();
B.button.addActionListener(anActionListener);
C.button.enableEvents(true);
D.button.enableEvents(AWTEvent.ACTION_EVENT_MASK);
A.float f=1/3;
B.int i=1/3;
C.float f=1.01;
D.double d=999d;
A.Java的源程序必须以".java"或".jav"扩展名保存
B.Java VM可以是软件也可以是硬件
C.Java使用解释器执行代码
D.用高级语言编写的代码可以让计算机理解并执行它们
A.扩展类Thread
B.实现接口Runnable
C.扩展类Runnable
D.实现接口Thread
A.mouseClicked
B.mouseEntered
C.mouseExited
D.mousePressed
E.mouseReleaseed
A.没有任何内容
B.居中位置有个按钮
C.左边有个按钮
D.右边有个按钮
E.一个按钮填充整个用户界面上
最新试题
在Hibernate 中关于数据库表主键,正确的说法有()
给定如下Java程序片断: class A{ public A (){ System.out.println("A"); } } class B extends A{ public B(){ System.out.println("B"); } public static void main(String[] args){ B b=new B(); } } 上述程序将()。
Struts框架的控制器主要由()负责
Hibernate关联维护中关于“一对一”描述正确的是()
在Hibernate 中关于缓存正确的说法有()
Struts中Logic标记库定义的标记能够执行下列哪些功能()
AOP中切入点描述正确的有()
在Java中,下列代码将输出()。 1. public class integerequals 2. { 3. public static void main (String args[]) 4. { 5. Integer a= new Integer(3); 6. Integer b= new Integer(3); 7. System.out.println(a==b); 8. } 9. }
Hibernate 中的查询参数类型有()
关于Spring的IoC说法正确的是()