This uses pygame to visualize Bubble Sort algorithm.
I decided to use line length as distinctive feature which will get sorted for best list/array visualization.
NOTE: This is a re-upload of a project I made several years ago.
Example list: [12, 58, 21, 13, 18, 42, 35, 49, 10, 3, 50, 28, 55, 1, 8, 3, 24, 49]
Result:
- Green: Pivot value to compare against
- Yellow: Current element being compared
- Red: Moving pivot index, establishing where next pivot should be
- Orange: Current element is also the moving pivot index
- Blue: All values being partitioned
- White: Currently ignored values
