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;
const int maxn = 3e5 + 5;
bool cmp1(const char &a, const char &b) { return a < b; }
bool cmp2(const char &a, const char &b) { return a > b; }
char s1[maxn], s2[maxn], s[maxn];
int main() {
  while (~scanf("%s%s", s1, s2)) {
    int n = strlen(s1);
    sort(s1, s1 + n, cmp1);
    sort(s2, s2 + n, cmp2);
    bool flag = true;
    int p = 0, q = 0, pd = (n + 1) / 2, qd = n / 2, u = 0, v = n - 1;
    for (int i = 0; i < n; i++) {
      if (flag) {
        if (s1[p] < s2[q]) {
          s[u++] = s1[p++];
        } else {
          s[v--] = s1[pd--];
        }
        flag = !flag;
      } else {
        if (s2[q] > s1[p]) {
          s[u++] = s2[q++];
        } else {
          s[v--] = s2[qd--];
        }
        flag = !flag;
      }
    }
    s[n] = '\0';
    printf("%s\n", s);
  }
  return 0;
}
