John R. answered 05/16/26
Developer with a passion for C++ and over 11+ years of experience
I'm resurrecting this 10 year old question with a response that's almost certainly overkill, but I couldn't resist, this was too fun to write.
There's no better way to demonstrate total understanding than to animate the algorithm processes during a sort, so that's what this code does...but, due to the character limit imposed by Wyzant (even though I'm well within the 10k limit, it's still not letting me post the solution here for some reason..?) I am sharing a link to the solution instead of the actual code.
Try this first:
https://onlinegdb.com/F2noBVoRT
If that link is dead, you can find the solution here:
https://drive.google.com/drive/folders/1jJAzOk8kdaD98zsUyePioFbCSHR1EGs-?usp=sharing
Then copy and paste that code into this online compiler:
https://www.onlinegdb.com/online_c++_compiler#