单项选择题

现有: 
class Parser (类)extends(继承) Utils {  
public static void main(String [] args) {  
System.out.print(输出打印)(new Parser().getInt("42")); 
}  
int getInt(String arg) {  
return Integer.parseInt(arg);   
}  
}  
class Utils {  
int getInt(String arg) throws Exception { return 42; } 
}  
结果为:()  

A. 42
B. 编译失败。
C. 无输出结果。
D. 运行时异常被抛出。

相关考题