本帖最后由 wangleixhlm 于 2014-5-28 22:13 编辑
- public class OuterClass
- {
- private double d1 = 1.0;
- //insert code here
- }
复制代码 插入内部类定义在注释部分,哪几个正确,为什么?
A. class InnerOne{
public static double methoda() {return d1;}
}
B. public class InnerOne{
static double methoda() {return d1;}
}
C. private class InnerOne{
double methoda() {return d1;}
}
D. static class InnerOne{
protected double methoda() {return d1;}
}
E. abstract class InnerOne{
public abstract double methoda();
}
|
|