arr=[-37.507,-3.263,40.079,27.999,65.213,-55.552];
arr.sort();
and the result is
arr=[-3.263,-37.507,-55.552,27.999,40.079,65.213]
Can any one help me what logic that "sort()" function is doing? Please explain me why "arr.sort();" gives the above result.? And other questions doesn't have the exact answer which explains what i am getting here.