题目内容

Calendar类中,用于为指定的日历字段增加或减去指定的时间量的方法是?( )

A. int get(int field)
B. void add(int field,int amount)
C. void set(int field,int value)
D. void set(int year,int month,int date)

查看答案
更多问题

在DateFormat类中定义了四个常量值用于作为参数传递给这些方法,其中FULL常量表示?( )

A. 完整格式
B. 长格式
C. 普通格式
D. 短格式

以下Math类的方法中,-4.4通过哪个方法运算后,结果为-5.0?

A. round()
B. min()
C. floor()
D. ceil()

String s = "abcdedcba";则s.substring(3,4)返回的字符串是以下选项中的哪个?

A. cd
B. de
C. d
D. e

阅读下面的程序:public class test { public static void main(String args[]) { int i; float f = 2.3f; double d = 2.7; i = ((int)Math.ceil(f)) * ((int)Math.round(d)); System.out.println(i); } } 程序执行后,运行结果为以下哪个选项?

A. 9
B. 5
C. 6
D. 6.1

答案查题题库