#include <bits/stdc++.h>
using namespace std;
char s1[1000010], s2[1000010];
int a[27], b[27];
int check() {
  while (1) {
    for (int i = 0; i < 26; i++)
      if (a[i] < b[i]) return i;
    for (int i = 0; i < 26; i++) a[i] -= b[i];
  }
}
int main() {
  scanf("%s%s", s1, s2);
  int len2 = strlen(s2);
  for (int i = 0; i < len2; i++) b[s2[i] - 'a']++;
  int len1 = strlen(s1);
  for (int i = 0; i < len1; i++)
    if (s1[i] <= 'z' && s1[i] >= 'a') a[s1[i] - 'a']++;
  for (int i = 0; i < len1; i++) {
    if (s1[i] == '?') {
      s1[i] = check() + 'a';
      a[s1[i] - 'a']++;
    }
  }
  printf("%s\n", s1);
}
