#include <iostream> using namespace std; int main(){ string s; getline(cin, s); char p; cin >> p; for(int i = 0; i < s.size(); i ++ ){ if(s[i] == p) s[i] = '#'; } cout << s << endl; return 0; }