单项选择题
已知有下面的类说明:
public class Test4
private float f=1.0f;
int m=12;
static int n=1;
public static void main(String args[])
Test4 e=new Test4();
在main()方法中,下面哪个的使用是正确的 ( )
A.f
B.this.n
C.Test4.m
D.Test4.f
点击查看答案&解析
<上一题
目录
下一题>
热门
试题
单项选择题
下列程序中的循环体将会被执行 ( ) public class ex26 public static void main(String[]args) int n=4; while(n<=8) System.out.println(n); n++;
A.8次
B.2次
C.4次
D.5次
点击查看答案&解析
单项选择题
类A定义如下: class A private int x=10; int getx() return x; class B extends A private int x=15; 需要覆盖getx()方法 在下述方法中可以在类B中覆盖getx()方法的是 ( )
A.int getx()…
B.int getx(floatf)…
C.float getx()…
D.double getx(floatf)…
点击查看答案&解析
相关试题
给出下面代码段:x处于什么范围时打印字符...