package _01_内容回顾; public class Test { public static void main(String[] args) { // 1 创建出来一个student 对象 给对象设置相关属性 Student student = new Student(); student.name = "zhangsan"; student.age = -18; // 调用方法 对象名.方法名(); student.show(); student.study(); student.sleep(); // 1 一个类是可以创建出来多个对象, 多个对象属性是完全可不一样 Student student1 = new Student(); student1.name = "lisi"; student1.age = 19; student1.show(); } }