package exercise.exercise01; /** * @author WanJl * @version 1.0 * @title ComputerStudent * @description * @create 2026/7/27 */ public class ComputerStudent extends Student{ private double javaScore; private double mySQLScore; public ComputerStudent(Integer id, String name, Integer age, String gender, double javaScore, double mySQLScore) { super(id, name, age, gender); this.javaScore = javaScore; this.mySQLScore = mySQLScore; } @Override public void study() { System.out.println("计算机专业学生"+this.getName()+"在学计算机"); } @Override public void lesson() { System.out.println("计算机专业学生"+this.getName()+"在上 Java 基础课"); } public double getJavaScore() { return javaScore; } public void setJavaScore(double javaScore) { this.javaScore = javaScore; } public double getMySQLScore() { return mySQLScore; } public void setMySQLScore(double mySQLScore) { this.mySQLScore = mySQLScore; } }