当前位置:SCJP程序员认证考试题库

问题:

[填空题]

Given the following code, write a line of code that, when inserted at the indicated location, will make the overriding method in Extension invoke the overridden method in class Base on the current object.  
class Base {  
public void print() {  
System.out.println("base");  
}  
}  
class Extention extends Base {  
public void print() {  
System.out.println("extension");  
// insert line of implementation here  
}  
} 
 public class Q294d {  
public static void main(String args[]) {  
Extention ext = new Extention();  
ext.print();  
}  
}  
Fill in a single line of implementation.()

商业化经营获得成功的第一家大众化报纸是()。 ["《纽约太阳报》","《泰晤士报》","《每日新闻》","《法国时报》"] 参加百度认证有哪些优势?() ["权威象征","收录提升","精准锁定有需求的客户","优化展现品牌优势"] 政府质量监督机构参加建设工程项目竣工验收会议的目的是()。 ["对建设过程质量情况进行总结,签发竣工验收意见书","对影响结构安全的工程实体质量进行检测","对影响使用功能的相关部分进行检查验收","对质量验收的程序、组织、方法、过程等进行监督"] 贸易保护的主要措施有() ["征收进口关税","实行进口配额","非关税壁垒","实行出口补贴","降低出口商品税率"] 建筑地面工程施工中,整体面层施工后,养护时间不应小于()d。 ["7","14","21","28"]

Given the following code, write a line of code that, when inserted at the indicated location, will make the overriding method in Extension invoke the overridden method in class Base on the current object.  
class Base {  
public void print() {  
System.out.println("base");  
}  
}  
class Extention extends Base {  
public void print() {  
System.out.println("extension");  
// insert line of implementation here  
}  
} 
 public class Q294d {  
public static void main(String args[]) {  
Extention ext = new Extention();  
ext.print();  
}  
}  
Fill in a single line of implementation.()

参考答案:

  参考解析

本题暂无解析

在线 客服