C++

Objectives :

  • myStackPushPop1.cpp
    A stack consists of a sequence of items, which should be thought of piled one on top of the other. Only the top item on the stack is accessible at any given time. It can be removed from the stack with an operation called pop. An item lower down on the stack can only be removed after all the items on top of it have been popped off the stack. A new item can be added to the top of the stack with an operation called push.
  • Code: myStackPushPop1.txt
 

Step: 1 Create a source file.

 

Step: 2 Edit and save Source file

Step: 3 Runtime Views:

Step: