#include <bits/stdc++.h>
using namespace std;
int A[27], An[27], At[27], tt, hur;
string s, t;
int main() {
  cin >> s;
  for (int i = 0; i < s.length(); i++)
    if (int(s[i]) == 63)
      tt++;
    else
      A[int(s[i]) - 96]++;
  cin >> t;
  for (int i = 0; i < t.length(); i++) At[int(t[i]) - 96]++;
  while (tt > 0) {
    for (int i = 1; i <= 26; i++)
      if (A[i] < At[i]) {
        int a = At[i] - A[i];
        if (a > tt) {
          An[i] += tt;
          tt = 0;
          break;
        }
        A[i] += a;
        An[i] += a;
        tt -= a;
      }
    for (int i = 1; i <= 26; i++) A[i] -= At[i];
  }
  for (int i = 0; i < s.length(); i++)
    if (int(s[i]) == 63) {
      for (int j = 1; j <= 26; j++)
        if (An[j] > 0) {
          hur = j + 96;
          An[j]--;
          break;
        }
      s[i] = char(hur);
    }
  cout << s << endl;
}
