Do you mean how to implement them with a std::vector? I wouldn't recommend do this in real code, as it is simply going to be very slow for large vectors, but here is a simple implementation.
Code:
#include <iostream>
#include <vector>
template <class T>
T PopFront(std::vector<T>& v) {
T ret = v[0];
v.erase(v.begin());
return ret;
}
template <class T>
void PushFront(std::vector<T>& v, const T& val) {
v.insert(v.begin(), val);
}
int main() {
std::vector<int> test;
for (int i = 0; i < 10; ++i) {
PushFront(test,i);
}
while (!test.empty()) {
std::cout << PopFront(test) << std::endl;
}
return 0;
}