Algorithm - (Performance|Running Time|Fast)


The performance of an algorithm can be assessed through the number of basic operations that it performs as a function of the length of the input numbers.

running time = # of lines of code executed.

Debugger definition

Running the algorithm in a debugger, every time we press enter, we advance with one line of the program through the debugger. Basically, the running time is just a number of operations executed, the number of lines of code executed.

How many times you have to hit enter on the debugger before the, program finally terminates, function of the input N gives us a performance metrics.


<MATH> \text{fast algorithm} \approx \href{case#worst}{\text{worst-­case running}} \text{ grows slowly with input size} </MATH> Usually want as close to linear (O(n)) as possible.

Powered by ComboStrap