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(int argc, char const *argv[]) {
  string s1, s2;
  vector<char> m1, m2;
  char c[300300];
  cin >> s1 >> s2;
  int n = s1.length();
  c[n] = '\0';
  for (int i = 0; i < n; i++) {
    m1.push_back(s1[i]);
    m2.push_back(s2[i]);
  }
  sort(m1.begin(), m1.end());
  sort(m2.rbegin(), m2.rend());
  int l = 0, r = n - 1, l1 = 0, r1 = n / 2, l2, r2 = n / 2 - 1;
  for (int i = 0; i < n; i++) {
    if (i % 2 == 0) {
      if (m1[l1] < m2[l2]) {
        c[l] = m1[l1];
        l1++;
        l++;
      } else {
        c[r] = m1[r1];
        r1--;
        r--;
      }
    } else {
      if (m1[l1] < m2[l2]) {
        c[l] = m2[l2];
        l2++;
        l++;
      } else {
        c[r] = m2[r2];
        r2--;
        r--;
      }
    }
  }
  printf("%s\n", c);
  return 0;
}
