Skip to content

Instantly share code, notes, and snippets.

@deadcoder0904
Created September 18, 2016 18:49
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save deadcoder0904/f3ca149076ffa50c9f24b5d50de40b37 to your computer and use it in GitHub Desktop.
Save deadcoder0904/f3ca149076ffa50c9f24b5d50de40b37 to your computer and use it in GitHub Desktop.
Parameters for Algorithms
PARAMETERS FOR ALGORITHMS
(1) Time Complexity -
Asymptotic Analysis
(2) Space Complexity or Memory Usage -
(a) In Place ( Constant Memory )
(b) Memory Usage Grows with Size of Input
(3) Stability -
A sorting algorithm is said to be stable if two objects with equal keys appear in the same order in sorted output as they appear in the input unsorted array.
(a) Some sorting algorithms are stable by nature like Insertion sort, Merge Sort, Bubble Sort, etc.
(b) Some sorting algorithms are unstable by nature like Heap Sort, Quick Sort, etc.
(4) Internal or External Sort -
(a) Internal Sort - Records stored in RAM or Main Memory
(b) External Sort - Records stored in Auxiliary Memory (Tapes or Disks)
(5) Recursive or Non-Recursive(Iterative) -
(a) Recursive - Quick or Merge Sort
(b) Non-Recursive - Insertion, Bubble & Selection Sort
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment