Re: MEDIAN,(BY SORT ARRAY)

So you're asking how to sort the array, or how to find the median without sorting the array?

Re: MEDIAN,(BY SORT ARRAY)

basically i have to workout with such a code,which's gonna calculate the median,and it's must/necessary condition that,before taking median of array; that particular array must be in sorted order...then my code has to calculate the median.simple! but em confused too,like yew,as these both have different codes in the internet various sites...so em unable to understand the logic as well as different codes...as their are may sorting algorithms ....kindly guide me thanks ! i have already calculated the mean,now i have to calculate the mode and median

--- Update ---

give me some logic only...not codes,but some statements...so that,atleast,i can understand what i jave to done,then i will come back with my rough code..nd yew have to sort out the problem,when i will gonna ask,thankx :)

Re: MEDIAN,(BY SORT ARRAY)

There is an Arrays.sort() method in many forms that will do the job for you, but it's not clear if you can use that.

If you must program your own sort method, the sorting algorithm is usually specified or you'd be expected to use one (or all) of a number of them you've discussed in class. Any clues?