怎样将下面一段代码从由大到小排序变为由小到大排序?
public void sumScoreSort()
{
Student stu;
double sum[]=new double[5];
for(int i=0;i<students.size();i++)
{
sum[i]=students.get(i).java+students.get(i).english+students.get(i).math+students.get(i).physics+students.get(i).chinese;
}
for(int i=0;i<students.size();i++)
{
Student stu1;
for(int j=i+1;j<students.size();j++)
{
if(sum[i]<sum[j])
{
stu1=students.get(i);
students.set(i,students.get(j));
students.set(j, stu1);
}
}
}
for(int i=0;i<students.size();i++)
{
System.out.print(i+1+":");
System.out.println(students.get(i).toString());
}
}
}