摘要:
类型转换and static //类型之间的转换:父 子 //高 低 Person obj=new Student(); //student01这个对象转换为Student类型.我们就可以使用Student类型的方法了 //子类转为父类会丢失自己的一些方法 Student student01=new 阅读全文
posted @ 2021-07-22 23:46
一颗苹果!!
阅读(45)
评论(0)
推荐(0)
摘要:
Static详解 package oop.Test06;public class Student { private static int age;//静态变量 多线程会用到 private double score;//非静态变量 public void run(){ } public sta 阅读全文
posted @ 2021-07-22 23:45
一颗苹果!!
阅读(33)
评论(0)
推荐(0)