2011年JAVA认证模拟题(38)
Q112 Which of the following are true?A A Dialog can have a MenuBar.
B MenuItem extends Menu.
C A MenuItem can be added to a Menu.
D A Menu can be added to a Menu.
Q113 Which method is used to s et the text of a Label object?
A setText()
B setLabel()
C setTextLabel()
D setLabelText()
Q114 What is the output of the following program?
class Question {
static int i = 1, j = 2;
static {
display(i);
}
public static void main (String[] args)
{
display(j);
}
static void display(int n) {
System.out.print(n);
}
}
A 1
B 2
C 12
D 21
Q112 CD
Q113 A
Q114 C
页:
[1]