日期:2014-05-17 浏览次数:20904 次
import java.util.Date;
public class MutilExtendsTest {
class A extends Object{
public void print(){
System.out.println("this is class A");
}
}
class B extends Date{
public void print(){
System.out.println("this is class B");
}
}
/**
* @param args
*/
public static void main(String[] args) {
// TODO Auto-generated method stub
new MutilExtendsTest().new A().print();
new MutilExtendsTest().new B().print();
}
}