Simple Function Program In Javascript Object Sorting