This project demonstrates various sorting algorithms with a visual representation using HTML, CSS, and JavaScript. You can visualize how different sorting algorithms like Bubble Sort, Insertion Sort, Quick Sort, Selection Sort, and Merge Sort work by observing the changes in bar heights and colors.
- Sorting Algorithms
- Bubble Sort
- Insertion Sort
- Quick Sort
- Selection Sort
- Merge Sort
- How to Run
- Demo
- Contributing
- License
Bubble Sort is a simple sorting algorithm that repeatedly steps through the list, compares adjacent elements, and swaps them if they are in the wrong order.
Insertion Sort is a simple sorting algorithm that builds the final sorted array one item at a time. It is efficient for small datasets but inefficient for large datasets.
Quick Sort is a divide-and-conquer algorithm that picks an element as a pivot and partitions the array around the pivot.
Selection Sort is a simple sorting algorithm that divides the input list into two parts: a sorted sublist and an unsorted sublist. It repeatedly finds the minimum element from the unsorted sublist and swaps it with the first unsorted element.
Merge Sort is a divide-and-conquer algorithm that divides the input array into two halves, sorts each half recursively, and then merges the two sorted halves.
1.Install my-project with npm
npm install my-project
cd my-project
2.Clone the repository:
git clone https://github.com/yourusername/sorting-visualization.git
cd sorting-visualization
3.Open index.html in a web browser to view the application.
https://sorting-visualizer-gilt-ten.vercel.app/
Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.
This project is licensed under the MIT License. See the LICENSE file for details.