From: Tagore on 21 Jul 2010 20:41 Hi, I am making a message application where I need to sort and partition messages according to sender names. All my message records are stored in a large array. I am looking for an in-place and stable sorting algorithm which can serve my purpose. Thanks,
From: Richard Heathfield on 21 Jul 2010 21:19 Tagore wrote: > Hi, > > I am making a message application where I need to sort and partition > messages according to sender names. > All my message records are stored in a large array. > I am looking for an in-place and stable sorting algorithm which can > serve my purpose. qsort will do it; simply specify sufficient key to guarantee stability (e.g. add a record number or something). -- Richard Heathfield <http://www.cpax.org.uk> Email: -http://www. +rjh@ "Usenet is a strange place" - dmr 29 July 1999 Sig line vacant - apply within
From: Stuart Golodetz on 22 Jul 2010 10:06 Tagore wrote: > Hi, > > I am making a message application where I need to sort and partition > messages according to sender names. > All my message records are stored in a large array. > I am looking for an in-place and stable sorting algorithm which can > serve my purpose. > > Thanks, If you're using C++, try std::stable_sort. Cheers, Stu
|
Pages: 1 Prev: Simple Hack To Get $2500 To Your PayPal Account. Next: Visual IDE for desktop-like web apps |