bcdef
abbbc
 z
y
 reddit
abcdef
 abc
aaa
 y
z
 cbxz
aaaa

bccdb
 z
 dfdeed
 aab
 y
 abac

#include <bits/stdc++.h>
using namespace std;
int dcmp(double x, double y) {
  return (fabs((x) - (y)) <= 1e-9) ? 0 : ((x) < (y)-1e-9) ? -1 : 1;
}
string olg, igr;
int freq[30], one[30], two[30];
char ans[300005];
int main(void) {
  cin >> olg >> igr;
  int n = olg.length();
  for (char c : olg) freq[c - 'a']++;
  int onePut = (n + 1) / 2;
  for (int(i) = (0); i <= (int)(25); (i)++) {
    if (freq[i] && onePut) {
      int used = min(onePut, freq[i]);
      one[i] = used;
      onePut -= used;
    }
    freq[i] = 0;
  }
  for (char c : igr) freq[c - 'a']++;
  int twoPut = n / 2;
  for (int(i) = (25); i >= (int)(0); (i)--) {
    if (freq[i] && twoPut) {
      int used = min(twoPut, freq[i]);
      two[i] = used;
      twoPut -= used;
    }
  }
  int st = 1;
  int ed = n;
  bool turnFirst = true;
  while (st <= ed) {
    if (turnFirst) {
      char mySmall, hisLarge;
      for (int(i) = (0); i <= (int)(25); (i)++) {
        if (!one[i]) continue;
        mySmall = (char)('a' + i);
        break;
      }
      for (int(i) = (25); i >= (int)(0); (i)--) {
        if (!two[i]) continue;
        hisLarge = (char)('a' + i);
        break;
      }
      if (mySmall < hisLarge) {
        ans[st++] = mySmall;
      } else {
        for (int(i) = (25); i >= (int)(0); (i)--) {
          if (!one[i]) continue;
          mySmall = (char)(i + 'a');
          break;
        }
        ans[ed--] = mySmall;
      }
      one[mySmall - 'a']--;
      turnFirst = false;
    } else {
      char myLarge, hisSmall;
      for (int(i) = (25); i >= (int)(0); (i)--) {
        if (!two[i]) continue;
        myLarge = (char)(i + 'a');
        break;
      }
      for (int(i) = (0); i <= (int)(25); (i)++) {
        if (!one[i]) continue;
        hisSmall = (char)(i + 'a');
        break;
      }
      if (myLarge > hisSmall) {
        ans[st++] = myLarge;
      } else {
        for (int(i) = (0); i <= (int)(25); (i)++) {
          if (!two[i]) continue;
          myLarge = (char)(i + 'a');
          break;
        }
        ans[ed--] = myLarge;
      }
      two[myLarge - 'a']--;
      turnFirst = true;
    }
  }
  for (int(i) = (1); i <= (int)(n); (i)++) cout << ans[i];
}
