Skip to content

ChemElecRx/sort_algorithms

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Sorting Visualization Program

This program implements several sorting algorithms and visualizes their execution using Matplotlib. The user can select a sorting algorithm and see a step-by-step visualization of how the algorithm sorts the input list.

Sorting Algorithms Implemented

  1. Radix Sort
  2. Bubble Sort
  3. Quick Sort
  4. Merge Sort
  5. Shell Sort
  6. Selection Sort
  7. Insertion Sort
  8. Binary Insertion Sort
  9. Heap Sort

How to Use

  1. Run the program.
  2. Choose a sorting algorithm by entering the corresponding number.
  3. View the visualization of the sorting process.
  4. After the sorting is complete, the program will ask if you want to visualize another sorting algorithm.

Requirements

  • Python 3.x
  • Matplotlib

Code Structure

  • BubbleSort: Implements the Bubble Sort algorithm and visualizes the sorting process.
  • InsertionSort: Implements the Insertion Sort algorithm and visualizes the sorting process.
  • SelectionSort: Implements the Selection Sort algorithm and visualizes the sorting process.
  • ShellSort: Implements the Shell Sort algorithm and visualizes the sorting process.
  • MergeSort: Implements the Merge Sort algorithm and visualizes the sorting process.
  • QuickSort: Implements the Quick Sort algorithm and visualizes the sorting process.
  • RadixSort: Implements the Radix Sort algorithm and visualizes the sorting process.
  • BinaryInsertSort: Implements the Binary Insertion Sort algorithm and visualizes the sorting process.
  • HeapSort: Implements the Heap Sort algorithm and visualizes the sorting process.

Visualization

The program uses Matplotlib to visualize the sorting process. Each bar represents an element in the list, and the height of the bar represents the value of the element. The bars move and change color as the sorting algorithm progresses, providing a visual representation of the sorting process.

License

This program is licensed under the MIT License.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages