问题
单项选择题
下列代码的输出结果是( )。 class parent void printme() System.out.println("parent"); class child extends parent void printme() System. out.println("child"); void printall() super, printme(); this.printme(); printme(); public class testpublic static void main(String args[]) child myc=new child(); myc.printall();
A.parentchild child
B.parent child parent C. parentchild D. 编译错误
答案
参考答案:A