RE: My job hunt progress - EC2! 03-04-2018, 01:41 AM
#14
(03-04-2018, 01:36 AM)phyrrus9 Wrote:(03-04-2018, 01:13 AM)Ender Wrote: Good luck! Seems like a nice job.
The first solution I thought of would have a really odd computational and memory complexity, reduced if there are no duplicate numbers. However, it would vary based on the size of the largest number in the array, so there is no guarantee to be above or below O(nlogn). (based on bucket sort, my favorite sorting algorithm) Later thoughts were less weird.
Keep in mind, has to work for ALL data sets, of any size > 1 that the computer can hold. The data constraints were
array of integers in range [-2147483647, 2147483647]
size of array is always > 1
never larger than maximum system memory (subtracting memory needed for program code, data, and OS)
all numbers are chosen at random and in no order
Then what if nlogn < 5? Your algorithm would be worse than nlogn there too.











![[+]](https://sinister.li/images/modern/collapse_collapsed.png)