Student Id: 901-767-730
The Big-O-Notation in Data structures
Introduction:-
The Big-O-Notation is done to test the efficiency of one algorithm or many algorithms of same code and the time duration it takes to run and to execute in the given input size or it can be also be defined as how algorithm or similar algorithms are execute more quickly in its worst case scenario or outcome.
Example: A programmer would want to execute his program or algorithm at an instance or he would like to have the output of his algorithm at an instance.
Certain factors are to be considered in The Big-O-Notation. Factors depending on Big-O-Notations are:-
Memory needed.
Time needed.
Size of N in the algorithm.
The Big-O-Notation is used in many different structures to calculate the efficiency of algorithms which are:-
Programming or Real-life programming.
Data Structures.
Size of N in the algorithm:-
Consider an algorithm having the given value as N, If N is the no of times or statements to be executed they are needed to be executed no of times as in sorting. The greater the value of N in the algorithm the slower the algorithm will take to execute with efficiency, the algorithm will definitely execute but will take larger amount of time compared to other algorithms having the same code with the smaller value of N. If even there is a loop function or two loop functions involved in an algorithm it is going to take a larger amount of time. This comparison can be also called as the Growth Rates of the value N in an algorithm. The N value in the algorithm can be of any mathematical expression depending on the mathematical expression the Growth Rates vary.
Growth rates or functions in the Big-O-Notation:
1. 1………Constant 2. Log(n)……..Logarithmic 3.N……..Linear 4.NLog(n)
5.