You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Here is where I store my notes on data structures and algorithms
Algorithm Design
Reasonable-looking algorithms can be easily be incorrect. Algorithms correctness must be proven.
Proving correctness of algorithms need clear and precise modelling of the problem. We need the set of allowed input instances and the required properties of the algorithm's output.
An important technique in algorithm design is to narrow the set of allowable instances until there is a correct and efficient algorithm.
The heart of any algorithm is an idea. If your idea is not clearly revealed when you express an algorithm, then you are using too low-level a notation to describe it.
Searching for counterexamples is the best way to disprove the correctness of a heuristic.
Modeling your application in terms of well-defined structures and algorithms is the most important single step towards a solution.
Algorithm Analysis
The Big Oh notation and worst-case analysis are tools that greatly simplify our ability to compare the efficiency of algorithms.
Logarithms arise whenever things are repeatedly halved or doubled.