Possible Duplicate:
How to sort an array of javascript objects?
I have a array myResponse.students[i]
I calculate the Total marks for every student in the array through some logic and now i want to sort the array based on total marks which i calculate. How to do this using javascript?