Driver Program
| 133 | |
| 134 | //Driver Program |
| 135 | int main(){ |
| 136 | Stack1 s1; |
| 137 | s1.push(1); |
| 138 | s1.push(2); |
| 139 | s1.push(3); |
| 140 | |
| 141 | while(s1.size() > 0){ |
| 142 | cout << s1.top() << " "; |
| 143 | s1.pop(); |
| 144 | } |
| 145 | |
| 146 | Stack2 s2; |
| 147 | s2.push(1); |
| 148 | s2.push(2); |
| 149 | s2.push(3); |
| 150 | while(s2.size() > 0){ |
| 151 | cout << s2.top() << " "; |
| 152 | s2.pop(); |
| 153 | } |
| 154 | |
| 155 | } |