Category: Efficient

Efficient

Binary tree search
Categories:  Search   Efficient  

Binary tree traversal to retrieve node. Goes left or right at each node to reach its target

Try it out!
Merge sort
Categories:  Sort   Efficient  

Splits array into one-element arrays and starts merging them into longer, sorted arrays

Try it out!
Count sort
Categories:  Sort   Efficient   Inefficient  

Counts number of occurences of each number, saves it, prints the occurences by going thorugh the count array

Try it out!
Quick sort
Categories:  Sort   Efficient  

Splits each array into two smaller arrays, left and right. Elements smaller than chosen pivot go left, rest goes right

Try it out!