小白不知道这个程序哪里出问题了报错说:为找不到符号?
程序代码:
abstract class Employee { private String name; private String id; private double pay; Employee(String name,String id,double pay) { this.name=name; this.id=id; this.pay=pay; } public abstract void work(); } class Manager extends Employee { private int bonus; Manager(String name,String id,double pay,int bonus) { super(name,id,pay); this.bonus=bonus; } public void work() { System.out.println("Manager work"); } } class ProfessionalEmployee extends Employee { ProfessionalEmployee(String name,String id,double pay) { super(name,id,pay); } public void work() { System.out.println("Professional work"); } } class AbstractDemo { public static void main(String[] args) { ProfessionalEmployee s=new ProfessionalEmployee(kuke,xxoodx,50000); s.work(); } }
报错说倒数第二行:“ProfessionalEmployee s=new ProfessionalEmployee(kuke,xxoodx,50000);”找不到符号???
求大神指点!