Timeline for Sever-sort an array
Current License: CC BY-SA 3.0
44 events
| when toggle format | what | by | license | comment | |
|---|---|---|---|---|---|
| Jan 29, 2024 at 19:51 | answer | added | bigyihsuan | timeline score: 0 | |
| Jan 29, 2024 at 17:20 | answer | added | noodle person | timeline score: 0 | |
| Jan 29, 2024 at 16:28 | answer | added | Xcali | timeline score: 0 | |
| Jan 29, 2024 at 6:29 | answer | added | l4m2 | timeline score: 0 | |
| Jan 29, 2024 at 1:59 | answer | added | pacman256 | timeline score: 1 | |
| Feb 11, 2021 at 22:57 | answer | added | Dominic van Essen | timeline score: 1 | |
| Feb 11, 2021 at 22:54 | answer | added | Leo | timeline score: 3 | |
| Feb 11, 2021 at 21:55 | answer | added | coltim | timeline score: 1 | |
| Feb 11, 2021 at 19:50 | answer | added | Giuseppe | timeline score: 1 | |
| Feb 11, 2021 at 19:37 | answer | added | caird coinheringaahing♦ | timeline score: 2 | |
| Dec 28, 2016 at 14:50 | answer | added | NikoNyrh | timeline score: 0 | |
| Dec 24, 2016 at 0:32 | answer | added | AvahW | timeline score: 0 | |
| Dec 23, 2016 at 4:31 | answer | added | rahnema1 | timeline score: 1 | |
| Dec 23, 2016 at 1:10 | answer | added | Sergei Patiakin | timeline score: 0 | |
| Dec 22, 2016 at 19:28 | answer | added | Martin Ender | timeline score: 1 | |
| Dec 22, 2016 at 18:47 | answer | added | Billywob | timeline score: 1 | |
| Dec 22, 2016 at 17:54 | comment | added | FlipTack | Here are the average number of severs for random list sizes from 1-20. Each one was run 10000 times, with the total severs counted, and then an average calculated. Note that the "random lists" were filled with uniform random elements 1-100. | |
| Dec 22, 2016 at 16:35 | comment | added | Nathan Merrill | It's definitely O(n^2). Rotating a sorted array by 1 causes causes the O(n^2) lower bound ([2,3,4,5,6,1]). However the upper bound is also O(n^2) (assuming a good implementation), as it is strictly better than bubble sort (as it swaps two numbers + possibly more) | |
| Dec 22, 2016 at 14:27 | comment | added | ETHproductions | Reversing is O(n), but reversing can be built right into the algorithm (that's what my JS answer does); since each iteration loops over each item in the array once, a single iteration is O(n). (I think...) | |
| Dec 22, 2016 at 13:23 | answer | added | nimi | timeline score: 1 | |
| Dec 22, 2016 at 11:58 | answer | added | Noodle9 | timeline score: 0 | |
| Dec 22, 2016 at 11:27 | comment | added | Jasen | @WheatWizard reversing an array doesn't require room for a copy of the array, only room for a single element. and is O(n). swap first and last elements then swap second and second last elements etc, when you get to the middle stop. | |
| Dec 22, 2016 at 8:59 | answer | added | Adám | timeline score: 2 | |
| Dec 22, 2016 at 8:17 | answer | added | Fatalize | timeline score: 3 | |
| Dec 22, 2016 at 3:26 | answer | added | Conor O'Brien | timeline score: 0 | |
| Dec 22, 2016 at 3:06 | answer | added | smls | timeline score: 0 | |
| Dec 22, 2016 at 1:23 | answer | added | manonthemat | timeline score: 4 | |
| Dec 22, 2016 at 0:18 | history | tweeted | twitter.com/StackCodeGolf/status/811727485960327168 | ||
| Dec 22, 2016 at 0:04 | answer | added | lynn | timeline score: 11 | |
| Dec 22, 2016 at 0:02 | answer | added | Dennis | timeline score: 15 | |
| Dec 21, 2016 at 23:59 | answer | added | LegionMammal978 | timeline score: 7 | |
| Dec 21, 2016 at 23:33 | answer | added | Maltysen | timeline score: 0 | |
| Dec 21, 2016 at 23:16 | answer | added | Arnauld | timeline score: 11 | |
| Dec 21, 2016 at 23:03 | answer | added | mbomb007 | timeline score: 4 | |
| Dec 21, 2016 at 22:59 | answer | added | ETHproductions | timeline score: 19 | |
| Dec 21, 2016 at 22:45 | comment | added | DJMcMayhem | That sounds right to me, however it's worth pointing out that reversing an array isn't a very efficient operation, so it's a slow O(n^2) | |
| Dec 21, 2016 at 22:40 | answer | added | FlipTack | timeline score: 5 | |
| Dec 21, 2016 at 22:39 | answer | added | user62802 | timeline score: 4 | |
| Dec 21, 2016 at 22:23 | comment | added | ETHproductions | @mbomb007 I don't understand big-o notation very well, but I think a single iteration is O(n). Multiply that by worst-case n iterations and you get O(n^2) (worst-case; best-case would be O(n), I think, for a single iteration). | |
| Dec 21, 2016 at 22:19 | answer | added | Blue | timeline score: 4 | |
| Dec 21, 2016 at 22:08 | comment | added | mbomb007 | What's the big-o of this sorting method? | |
| Dec 21, 2016 at 22:07 | answer | added | Emigna | timeline score: 5 | |
| Dec 21, 2016 at 22:03 | answer | added | Luis Mendo | timeline score: 8 | |
| Dec 21, 2016 at 21:46 | history | asked | ETHproductions | CC BY-SA 3.0 |