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 s, t;
  cin >> s;
  cin >> t;
  int n = s.length();
  int ans[n];
  sort(s.begin(), s.end());
  sort(t.begin(), t.end(), greater<int>());
  int j = 0, k = 0, beg = 0, send = n - 1;
  for (int i = 1; i <= n; i++) {
    if (s[j] <= t[k] && i % 2 == 1) {
      ans[beg] = (int)s[j];
      beg++;
      j++;
    } else if (s[j] > t[k] && i % 2 == 0) {
      ans[send] = (int)t[k];
      send--;
      k++;
    } else if (s[j] <= t[k] && i % 2 == 0) {
      ans[beg] = (int)t[k];
      k++;
      beg++;
    } else if (s[j] > t[k] && i % 2 == 1) {
      ans[send] = (int)s[j];
      j++;
      send--;
    }
  }
  for (int i = 0; i < n; i++) printf("%c", ans[i]);
  return 0;
}
