4.7

学习内容: 多态转型:向上转型 Animal a = new Cat(); a.eat(); 向下转型 Cat c = (Cat)a; c.eat(); 抽象方法没有方法体,抽象类中有抽象方法 抽象类 public abstract class Animal()

posted on 2024-04-07 22:31  HA_wind  阅读(11)  评论(0)    收藏  举报

导航