Ijrar research Journal



Yüklə 0,49 Mb.
Pdf görüntüsü
səhifə7/8
tarix02.06.2023
ölçüsü0,49 Mb.
#115224
1   2   3   4   5   6   7   8
IJRAR19L2026

 
 


© 2020 IJRAR September 2020, Volume 7, Issue 3 www.ijrar.org (
E-ISSN 2348-1269, P- ISSN 2349-5138

IJRAR19L2026 
International Journal of Research and Analytical Reviews (IJRAR) 
www.ijrar.org
 
121 
TABLE

C
OMPARISONS ON 
B
ASIS OF 
C
OMPLEXITY AND 
O
THER 
F
ACTORS
 
No 
 
Sorting Algorithm 
 
Best Case 
 
Average Case 
 
Worst Case 
 
Stable 

Bubble Sort 
O(n) 
O(n*n) 
O(n*n) 
Yes 

Selection Sort 
O(n*n) 
O(n*n) 
O(n*n) 
No 

Insertion Sort 
O(n) 
O(n*n) 
O(n*n) 
Yes 

Merge Sort 
O(nlogn) 
O(nlogn) 
O(nlogn) 
Yes 

Quick Sort 
O(nlogn) 
O(nlogn) 
O(n*n) 
No 
IV.
 
C
ONCLUSIONS
 
This paper discusses well-known sorting algorithms, their code and running time. In the previous work section, people have 
done a comparative study of sorting algorithms. Nowadays, some of them compared the running time of algorithms on real 
computers on a different number of inputs which is not much use because the diversity of computing devices is very high. This 
paper compares the running time of their algorithms as a mathematical entity and tries to analyse as an abstract point of view. 
This paper describes five well-known sorting algorithms and their running time complexity and their stability. To determine the 
good sorting algorithm, the time complexity is the main consideration but other factors include handling various data types
consistency of performance, the complexity of code and the stability. From the above discussion, we can conclude every sorting 
algorithm has some advantages and disadvantages of their usage and the programmer must choose according to his or her 
requirement of sorting algorithms.

Yüklə 0,49 Mb.

Dostları ilə paylaş:
1   2   3   4   5   6   7   8




Verilənlər bazası müəlliflik hüququ ilə müdafiə olunur ©www.genderi.org 2024
rəhbərliyinə müraciət

    Ana səhifə