#include <bits/stdc++.h>
using namespace std;
string s, t;
int num_s[1005];
int num_t[1005];
int num_w[1005];
int main() {
  cin >> s >> t;
  for (int i = 0; i < s.size(); i++) num_s[s[i]]++;
  for (int i = 0; i < t.size(); i++) num_t[t[i]]++;
  int ans = 0;
  while (1) {
    int flag = 0;
    for (int i = 'a'; i <= 'z'; i++) {
      if (num_s[i] >= num_t[i]) {
        num_s[i] -= num_t[i];
      } else if (num_s[i] + num_s['?'] >= num_t[i]) {
        num_s['?'] -= num_t[i] - num_s[i];
        num_w[i] += num_t[i] - num_s[i];
        num_s[i] = 0;
      } else {
        num_w[i] += num_s['?'];
        num_s[i] = 0;
        flag = 1;
        break;
      }
    }
    if (flag) break;
  }
  int now = 'a';
  for (int i = 0; i < s.size(); i++) {
    if (s[i] == '?') {
      for (int j = now; j <= 'z'; j++) {
        if (num_w[j] == 0) continue;
        num_w[j]--;
        now = j;
        printf("%c", now);
        break;
      }
    } else
      printf("%c", s[i]);
  }
  return 0;
}
