Stack variant tracking minimum or maximum element efficiently
Explain code with DocComment! Try out your own code!