3 ms·
Friends don't let friends use bubble sort. In fact friends don't even let enemies use bubble sort, if they have an ounce of humanity. Edit to actually answer
by iainmerrick 8y ago
Friends don't let friends use bubble sort.
In fact friends don't even let enemies use bubble sort, if they have an ounce of humanity.
Edit to actually answer the question: I wonder if it's something to do with some specific dataset having to be sorted in a particular way? i.e. where you'd normally use a stable sort, but the code accidentally depends on a specific unstable sort.
- iainmerrick 8y agoOh, wait, bubble sort is stable so it can't be that. Any other theories?
- anonymfus 8y ago>Any other theories? 1. Excel needs stable sort but OSX sort is unstable. 2. Performance deoptimisation to make Excel perform worse.
- iainmerrick 8y agoThere are any number of better ways to fix 1, though! 2 occurred to me too, but surely that’s too cynical. It would make Macs look bad more than Excel itself. Maybe it’s a bit of both. They needed a fix for 1, but they didn’t care about Excel performance at all so someone just spent 20 seconds doing a quick bodge job.
- saagarjha 8y agoMaybe because the software has a race condition around sorting which requires the use of a slower sort?
- r00fus 8y agoIs it wrong to ask if Microsoft intended it to be slow? Mac Outlook on a recent MBP is noticeably slower (usability impact) than a similar version of Outlook on my Windows VM on the same machine against the same account (30k items, 5GB-ish)