#include <iostream> using namespace std; const int N = 100010; int main() { int n; int stk[N],tt = -1; cin >> n; while(n--) { string op; cin >> op; if(op == "push") { int x; cin >> x; stk[ ++ tt] = x; } else if(op == "pop") { if(tt == -1) cout << &qu...