填空题
在深度为5的完全二叉树中,度为2的结点数最多为
【1】
。
【参考答案】
O
点击查看答案&解析
<上一题
目录
下一题>
热门
试题
单项选择题
下面程序段的输出结果是 public class Test{ public static void main(Stringargs[]){ int x,y; x=(int)Math.sqrt(5) 2+(int)Math.random()*5 2; y=(int)Math.sqrt(3) 2+(ht)Math.random()*3 2; if(x>y) System.out.println(”x>y”); else if(x=y) System.out.println(”x=y”); else System.out.Println(”x<y”); } }
A.x>y
B.x=y
C.x<y
D.编译错误
点击查看答案&解析
单项选择题
下面程序段的输出结果是 class Base { int i; Base() { add(1); } void add(int v) { i+=v; } void print() { System.out.println(i); } } class Extension extends Base { Extension() { add(2); } void add(int v) { i+=*2; } } public class Test { public static void main(String args[]) { bogo(new Extension()); } static void bogo(Base b) { b.add(8); b.print(); } }
A.9
B.18
C.20
D.22
点击查看答案&解析
相关试题
下面的程序是列出目录C:\Test中所有的.t...
下面程序段是创建一个Date类的对象并把它串...
编译Java Applet源程序文件产生的字节码文...
关于文件名的处理中,测试当前文件是否目录...
Java语言的循环语句包括for语句、do-while...