Academic Journal of Computing & Information Science, 2024, 7(10); doi: 10.25236/AJCIS.2024.071003.
Xu Dan1, Zhao Haomin2
1Department of Information Technology and Engineering, Guangzhou College of Commerce, Guangzhou, China
2Modern Information Industry Department, Guangzhou College of Commerce, Guangzhou, China
This article delves into Bubble Sorting and Quick Sorting in exchange sorting algorithms, and implements and tests their performance on different datasets using the Java programming language. This article provides a detailed analysis of the time and space complexity of two algorithms using a randomly generated dataset, and compares their advantages and disadvantages in practical applications. The experimental results indicate that Quick Sorting has higher efficiency in most cases, especially when dealing with large-scale datasets. However, Bubble Sorting can also demonstrate good performance in specific scenarios, such as when the data is essentially ordered.
Bubble Sorting; Quick Sorting; Space Complexity; Time Complexity
Xu Dan, Zhao Haomin. Analysis and Comparison of Exchange Sorting Algorithms. Academic Journal of Computing & Information Science (2024), Vol. 7, Issue 10: 16-23. https://doi.org/10.25236/AJCIS.2024.071003.
[1] Cormen T H, Leiserson C E, Rivest R L, et al. Introduction to Algorithms (3rd ed.)[M]. MIT Press. 2009.
[2] Yan Weimin, Li Dongmei, Wu Weimin. Data Structures (C Language Version, 2nd Edition) [M]. Tsinghua University Press, 2022.
[3] Smith J, Johnson M. Enhanced Bubble Sort Algorithm with Adaptive Thresholding[J]. Journal of Advanced Computing Research, 2022, 15(3): 234-246.
[4] Hoare, C. A. R. Algorithm 64: Quicksort[J]. Communications of the ACM, 1961,4(7): 321-322.
[5] Bayardo R J , Miranker D P . A Complexity Analysis of Space-Bounded Learning Algorithms for the Constraint Satisfaction Problem[J].AAAI Press, 1996, 2(03): 15-24.
[6] Huang H, Su J, Zhang Y, et al. An experimental method to estimate running time of evolutionary algorithms for continuous optimization[J]. IEEE Transactions on Evolutionary Computation, 2023, 27(4), 1234-1245.