Skip to content

Instantly share code, notes, and snippets.

@jasonpilz
Forked from stevekinney/gist:9e9cfeb225c8133fda73
Last active February 7, 2016 01:15
Show Gist options
  • Save jasonpilz/215616099ff1a60cb2e7 to your computer and use it in GitHub Desktop.
Save jasonpilz/215616099ff1a60cb2e7 to your computer and use it in GitHub Desktop.

Reference To: Sorting Algorithms in JavaScript

**Respond to this question in your fork: "What are some of the balances and trade offs between different sorting algoritms?"

###COMPARISON:

Bubble Sort Insertion Sort Merge Sort
Pros Easy to Implement
Stable sort
Good if short on space
Stable sort
Fastest
Cons
Not Stable sort
Slow as eff
Not good for large data Need lots of resources to use
O(n) O(n2) O(n2) O(n log n)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment