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 N = 1e7;
char ans[N], s1[N], s2[N];
int main() {
  cin >> s1 >> s2;
  int len = strlen(s1);
  int n = (len + 1) / 2;
  sort(s1, s1 + len);
  sort(s2, s2 + len);
  int flag = 1, k = 0, t = len - 1, l1 = 0, l2 = n, h1 = n - 1, h2 = len - 1;
  int l = 0, r = len - 1;
  while (l <= r) {
    if (s1[l1] >= s2[h2])
      ans[r--] = s1[h1--];
    else
      ans[l++] = s1[l1++];
    if (l > r) break;
    if (s1[l1] >= s2[h2])
      ans[r--] = s2[l2++];
    else
      ans[l++] = s2[h2--];
  }
  ans[len] = '\0';
  cout << ans << endl;
  return 0;
}
