Draw Graphs and Visualize Algorithms (Python3)
Built using the Pygame Library
pip install pygame
'ADD' button adds a new node to the canvas
Press 's' while cursor is on a node to define it as the source
Press 'd' while cursor is on a node to define it as the destination
Press 'l' while cursor is on a node to initialize a node link. Press 'l' again on another node to complete the link
Press 'Enter' to calculate Path from source to destination
Press 'space' to print the current graph
Path will be drawn using red color
Breadth First Search:
Depth First Search:
- Insertion Sort
- Bubble Sort
- Heap Sort
- Counting Sort
- Cocktail Shaker Sort
- Merge Sort
- Shell Sort
- Selection Sort
- Quick Sort
Execute run.py from every folder
Press 'space' to shuffle the list
Press 'Enter' to begin sorting
Modify the 'NUMBER_OF_ELEMENTS' variable in run.py to increase/decrease the number of elements
Insertion Sort:
Bubble Sort: