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;
ostream &operator<<(ostream &a, const vector<int> &b) {
  for (auto k : b) cout << k << " ";
  return a;
}
const int INF = 1e18;
signed main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  string a, b;
  cin >> a >> b;
  sort((a).begin(), (a).end());
  sort((b).begin(), (b).end());
  reverse((b).begin(), (b).end());
  int n = a.size();
  string ans(n, '?');
  int af = 0, alst = (n + 1) / 2 - 1;
  int bf = 0, blst = n / 2 - 1;
  int f = 0, lst = n - 1;
  for (int i = 0; i < n; i++) {
    if (i & 1) {
      if (b[bf] > a[af] || b[blst] <= a[af]) {
        ans[f] = b[bf];
        bf++;
        f++;
      } else {
        ans[lst] = b[blst];
        blst--;
        lst--;
      }
    } else {
      if (a[af] < b[bf] || a[alst] <= b[bf]) {
        ans[f] = a[af];
        af++;
        f++;
      } else {
        ans[lst] = a[alst];
        alst--;
        lst--;
      }
    }
  }
  cout << ans;
}
