-
Notifications
You must be signed in to change notification settings - Fork 0
Algorithms
Link to my repo on Python Algorithms: Python Problem Solving
A breadth-first search is a style of searching where you check every child node at the same level for your intended value before moving onto the next level of child nodes.
A depth-first search is sort of the inverse of a breadth-first search. With depth-first, you take each child branch as far as you can down the tree, then backtrack up to the last-visited parent node after reaching the end of the given branch.
With a Big(O) of n•log2(n)+n
Merge sort is a particularly efficient sorting algorithm for large data sets. Merge sort works by splitting a given input array into two sorted halves, then traversing through each element in those two arrays and placing the smaller element into your output array. It recurses through the entire array, splitting in two again and again until each element is of length 1 or 0, then simply placing each known array in sorted order.