第3个回答 2012-10-11
public static void main(String[] args) {
// TODO Auto-generated method stub
Object[] obj=null;
int[] l=null;
int m=0;
for(int i=0;i<10;i++){
People people = new People();
people.setHeight(i);
obj[i]=people;
}
for(Object k:obj){
l[m] =(People)k.getHeight;
m++;
}
Arrays.sort(l);
}本回答被提问者采纳