class Person
{
private int age;
private String name;
public void tell(){
System.out.println("姓名是:"+getAge()+"年龄是:"+getName());
}
public String getName(){
return name;
}
public void setName(String n){
name = n;
}
public int getAge(){
return age;
}
public void setAge(int b){
age = b;
}
}
public class Mn
{
public static void main (String args[]){
Person per = new Person();
per.setAge = (21);
per.setName =( "李");
per.tell();
}
为什么红色标记处会出错
}