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

bccdb
 z
 dfdeed
 aab
 y
 abac

#include <bits/stdc++.h>
int main() {
  std::istream& is = std::cin;
  std::ostream& os = std::cout;
  std::string s, t, u;
  std::getline(is, s);
  std::getline(is, t);
  std::sort(s.begin(), s.end());
  std::sort(t.begin(), t.end());
  int n = s.length();
  u.resize(n);
  int sl = 0, sr = n / 2 + n % 2 - 1, tl = n / 2 + n % 2, tr = n - 1, ul = 0,
      ur = n - 1;
  for (int m = 0; m < n; m++) {
    if (m % 2 == 0) {
      if (s[sl] < t[tr])
        u[ul++] = s[sl++];
      else
        u[ur--] = s[sr--];
    } else {
      if (t[tr] > s[sl])
        u[ul++] = t[tr--];
      else
        u[ur--] = t[tl++];
    }
  }
  os << u;
}
