虚方法和多态

 

 

Pet[] pets = new Pet[] {new Dog("Jack"),new Cat("Tom")};

posted @ 2018-10-21 22:17  Deepsleepinger  阅读(95)  评论(0编辑  收藏  举报