An interactive Merge Sort Visualizer that brings the sorting algorithm to life through real-time animations. This project helps you clearly understand how Merge Sort works by visually showing each step of the process.
This visualizer demonstrates the Merge Sort algorithm, a classic example of the divide and conquer approach. It splits a list into smaller parts, sorts them, and merges them back together — all while displaying the process step-by-step.
This project is ideal for:
- Students learning algorithms
- Developers revising data structures
- Anyone who prefers visual learning
- 🎥 Real-time sorting visualization
- 🎮 Interactive GUI with buttons
- 🔄 Toggle between ascending and descending order
- ⚡ Smooth step-by-step animation using generators
- 🎨 Clean and simple interface
-
Each value in the dataset is represented as a vertical bar
-
The algorithm:
- Recursively splits the array
- Compares elements
- Merges them in sorted order
-
Every important step is rendered visually, making it easy to follow the logic
- Start Button → Begin sorting visualization
- New List Button → Generate a new random list
- Ascending Button → Set sorting order to ascending
- Descending Button → Set sorting order to descending
- M Key (
M) → Select Merge Sort - Close Window → Exit the application
- Sorting starts only when no process is running
- Sorting order cannot be changed during execution
- Generate a new list to restart visualization
- Understand Merge Sort step-by-step
- Learn recursion and divide & conquer
- Improve algorithm visualization skills
- Add more sorting algorithms
- Adjustable animation speed
- Custom input support
- Pause/Resume functionality
This project is open-source and available under the MIT License.