- 博客(1)
- 收藏
- 关注
原创 子类继承父类的静态属性
Java 子类继承父类静态属性后,两者是共享的 public class Father{ protected static String money; protected String getMoney(){ return money; } } public class Son extends Father{ public static void main(String[] args){ Father.money = "100"; Son.money = "5"; Syste
2020-10-15 15:50:29 671
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人