This project is a visualisation tool for sorting algorithms, built using the pygame library in Python. It allows you to visualise both Bubble Sort and Insertion Sort, with options to reset the list, start sorting, and choose between ascending and descending orders. The visualisation now includes real-time complexity analysis, showing the number of comparisons and swaps as the sorting progresses.
- Real-time Visualisation: Watch sorting algorithms operate step by step.
- Real-time Complexity Metrics: Displays the number of comparisons and swaps during the sorting process.
- Two Sorting Algorithms: Bubble Sort and Insertion Sort are currently supported.
- Custom Controls: Reset the list, toggle between sorting algorithms, and switch between ascending/descending orders.
- R: Reset the list to a new randomly generated set of numbers.
- SPACE: Start the sorting process.
- A: Set sorting to ascending order.
- D: Set sorting to descending order.
- I: Switch to Insertion Sort.
- B: Switch to Bubble Sort.
Whether you're a beginner looking to understand sorting or just love visualising code in action, this project is for you. Have fun sorting! 😊