#include #include #include #include using namespace std; vector < int > V ; int main(){ // freopen("a.in","r",stdin) ; int n ; cin >> n ; int o ,x ; while (n--){ cin >> o; if ( o == 1){ cin >> x ; V.push_back(x); } else if (o == 2){ V.pop_back(); } else if (o == 3){ cin >> x ; bool k = false ; for(auto i :V){ if(i <= x){ k = true ; cout << i << " " ; } } if (!k)cout << "Empty" ; cout << '\n'; } } return (0); }