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 main() {
  string a, b;
  cin >> a >> b;
  int len = a.length();
  int ta[len], tb[len];
  for (int i = 0; i < len; i++) {
    ta[i] = a[i];
    tb[i] = b[i];
  }
  sort(ta, ta + len);
  sort(tb, tb + len);
  char ans[len + 1];
  ans[len] = '\0';
  if (len & 1) {
    ans[len - 1] = ta[len / 2];
    for (int i = 0; i < len / 2; i++) {
      ans[2 * i] = ta[i];
      ans[2 * i + 1] = tb[len - i - 1];
    }
    if (ans[len - 1] > ans[len - 2]) {
      int t = ans[len - 1];
      ans[len - 1] = ans[len - 2];
      ans[len - 2] = t;
    }
  } else {
    for (int i = 0; i < len / 2; i++) {
      ans[2 * i] = ta[i];
      ans[2 * i + 1] = tb[len - i - 1];
    }
  }
  cout << ans << endl;
  return 0;
}
