#include <bits/stdc++.h>
using namespace std;
int main() {
  string a, b;
  cin >> a >> b;
  vector<char> ans;
  long long int cnt[27];
  memset(cnt, 0, sizeof(cnt));
  for (long long int i = 0; i < a.length(); i++) {
    if (a[i] == '?')
      cnt[26]++;
    else
      cnt[a[i] - 'a']++;
  }
  while (cnt[26] != 0) {
    for (long long int i = 0; i < b.length(); i++) {
      if (cnt[26] == 0) break;
      long long int who = b[i] - 'a';
      if (cnt[who] > 0)
        cnt[who]--;
      else {
        ans.push_back(b[i]);
        cnt[26]--;
      }
    }
  }
  long long int xxx = 0;
  for (long long int i = 0; i < a.length(); i++) {
    if (a[i] == '?')
      cout << ans[xxx++];
    else
      cout << a[i];
  }
  return 0;
}
