Dog dog = new Dog(); Animal animal = dog;
可以的 写成Animal animal=new Dog(); 这就是标准的对象的多态形式 (前提Animal是Dog的父类)