0
我写了这个,但我不明白这是什么。在一行中一起创建父子类的对象?
Public ClassA { //some methods here } Public ClassB extends ClassA { Public static void main(String[] args) { ClassA abc=new ClassB //What is purpose of this line and what advantage it gives us. I accidently wrote this but compiler (Eclipse not generating any error on this statement). }