if there is no space constraint we can use counting sort .. with O(logm)
space and time complexity will be O(n)

On Fri, Jun 25, 2010 at 5:51 PM, sharad kumar <sharad20073...@gmail.com>wrote:

> You are given an unordered sequence of n integers with many duplications,
> such that the number of distinct integers in the sequence is O(log n).
> Design a sorting algorithm and its necessary data structure(s), which can
> sort the sequence using at most O(n log(log n)) time.
>
> Give the detailed design.
>
> --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algoge...@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com<algogeeks%2bunsubscr...@googlegroups.com>
> .
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>



-- 
With Regards,
Jalaj Jaiswal
+919026283397
B.TECH IT
IIIT ALLAHABAD

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algoge...@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.

Reply via email to