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 a, b;
multiset<char> x, y;
string ans;
int main() {
  cin >> a >> b;
  ans.resize(a.length());
  int n = a.length();
  sort(a.begin(), a.end());
  sort(b.begin(), b.end());
  if (n % 2 == 0) {
    for (int i = 0; i < n / 2; ++i) {
      x.insert(a[i]);
      y.insert(b[n - i - 1]);
    }
  } else {
    for (int i = 0; i < n / 2 + 1; ++i) {
      x.insert(a[i]);
    }
    for (int i = 0; i < n / 2; ++i) {
      y.insert(b[n - i - 1]);
    }
  }
  int st = 0, en = (int)a.length() - 1;
  for (int i = 0; i < a.length(); ++i) {
    auto it = x.begin();
    char mn = *it;
    char mx;
    auto it1 = y.end();
    if (y.empty()) {
      mx = 'a';
    } else {
      it1--;
      mx = *it1;
    }
    if (i % 2 == 0) {
      auto itFirst = x.end();
      itFirst--;
      char maxFirst = *itFirst;
      if (mn >= mx) {
        ans[en--] = maxFirst;
        x.erase(itFirst);
      } else {
        ans[st++] = mn;
        x.erase(it);
      }
    } else {
      auto itSecond = y.begin();
      char minSecond = *itSecond;
      if (mn >= mx) {
        ans[en--] = minSecond;
        y.erase(itSecond);
      } else {
        ans[st++] = mx;
        y.erase(it1);
      }
    }
  }
  cout << ans;
  return 0;
}
