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;
string oleg, igor;
string res;
int main() {
  ios::sync_with_stdio(false);
  cin >> oleg >> igor;
  sort(oleg.begin(), oleg.end());
  sort(igor.begin(), igor.end());
  res = oleg;
  int n = igor.size();
  int os = 0, oe = (n - 1) / 2;
  int ie = n - 1, is = (n + 1) / 2;
  int rs = 0, re = n - 1;
  for (int i = 0; i < oleg.size(); i++) {
    if (i % 2 == 0) {
      if (oleg[os] < igor[ie]) {
        res[rs++] = oleg[os++];
      } else {
        res[re--] = oleg[oe--];
      }
    } else {
      if (igor[ie] > oleg[os]) {
        res[rs++] = igor[ie--];
      } else {
        res[re--] = igor[is++];
      }
    }
  }
  cout << res << endl;
}
