Question: C++ Using Vector to simulate a stack class.Using the Vectors, complete the stack class. Use push, pop, and peek functions. You should at least have
C++
Using Vector to simulate a stack class.Using the Vectors, complete the stack class. Use push, pop, and peek functions. You should at least have 2 constructors: one that creates an empty stack, and one that creates a stack with one initial value. You also need at least 3 functions: push, pop, and peek. You are allowed to use whichever data type you see fit. Fill in some lines in the main function to show that your code is working.
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
