// 雇员编号 姓名 职位 基本工资 佣金等信息 package study; class Enr{ private int number; // 编号 private String fullName; // 姓名 private String position; // 职位 private int wages; // 工资 private int commission; // 佣金 public Enr(){} public Enr(int n,String f,String p,int w,int c){ setNumber(n); setFullName(f);//出错 setPosition(p);//出错 setWages(w); setCommission(c); } public String getlnfo(){ return "编号"+number+" "+ "姓名"+fullName+" "+ "职位"+position+" "+ "工资"+wages+" "+ "佣金"+commission; } public int setNumber(int n){ number = n; } public String setFullName(Srting f){ fullName = f; } public Srting setPosition(Srting p){ position = p; } public int setWages(int w){ wages = w; } public int setCommission(int c){ commission = c; } public int getNuymber(){ return number; } public Sttring getFullName(){ return fullName; } public String getPosition(){ return position; } public int getWages(){ return wages; } public int getCommission(){ return commission; } } public class practice{ public static void main(String args[]){ Enr study1 = new Enr(6666,"?????","////",6666,0.0) // 出错 System.out.println(study1.getlnfo()); } }