What is Stack ?
According to an English dictionary it means:
A pile of objects, typically one that is neatly arranged.
Same is the case in Computer programming.
What Is Stack In Computer Science perspective?
Stack is an abstract data that contains set of elements, it follows two principles PUSH to add an element and POP to remove an element.
Operation Of Stack In Real Life:
Assume a box open from the top. We take some books and stack them one on the other inside the box until the box is having no space left. The closed end is your front end and opening is your rear end. Just as a cargo plane, you load things up in the rear of the plane. Got it? It is easy right? You just have to think of stacking in this box like you do in a cargo plane.
Cockpit of cargo plane = Front end of box
Back door of cargo plane = Rear end of the box