Re: problem on medians
- From: "Malcolm McLean" <regniztar@xxxxxxxxxxxxxx>
- Date: Thu, 31 May 2007 07:38:10 +0100
"Ajinkya" <kaleajinkya@xxxxxxxxx> wrote in message news:1180589789.498330.85780@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
What are the least no. of comparisons required to find the median of aIf it is not homework then copy the numbers to a temporary array, sort them with qsort(), and take the middle.
set of n integers ?
Which is the best algorithm for this?
PS: not a homework question!
There might be a cleverer way of doing it, but it is pointless in a practical app.
--
Free games and programming goodies.
http://www.personal.leeds.ac.uk/~bgy1mm
.
- References:
- problem on medians
- From: Ajinkya
- problem on medians
- Prev by Date: Re: problem on medians
- Next by Date: Re: normalization of pointers...
- Previous by thread: Re: problem on medians
- Next by thread: problem on medians
- Index(es):