#include #include using namespace std; int main(){ string s; cin >> s; int n = s.size(); int piv = 0; int mode = 0; while(piv < n){ if (s[piv] == '#'){ mode ^= 1; }else if (mode == 1){ cout << s[piv]; } piv++; } cout << '\n'; }