Stack graphical representation using C++