equals复写
public boolean equals(object o){
if(this==o) return ture;
if(!o instanceof Monkey)
return ture;
final Monkey other=(Monkey)o;
if(this.name.equals(other.name)
//1为什么这里other可以直接访问name属性(name已封装)
return ture;
else
return false;
}
Monkey m1=new Monkey();
Monkey m2=new Monkey();