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;
string s_r;
int a, b, c;
string s1, s2;
int h1[300], h2[300];
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  cin >> s1 >> s2;
  s_r = s1;
  int i1 = 0, i2 = 0;
  int l = s1.length();
  for (int i = 0; i < l; ++i) h1[s1[i]]++;
  for (int j = 0; j < l; ++j) h2[s2[j]]++;
  for (int i = 0; i < 300; ++i) {
    for (; h1[i]; h1[i]--) s1[i1++] = i;
  }
  for (int i = 0; i < 300; ++i) {
    for (; h2[i]; h2[i]--) s2[i2++] = i;
  }
  i1 = 0, i2 = l - 1;
  int end = l - 1;
  int x = 0;
  int N = l;
  for (int i = 0; i <= end;) {
    if (x == 0) {
      if (s1[i1] < s2[i2]) {
        s_r[i] = s1[i1];
        i1++;
        ++i;
      } else {
        s_r[end] = s1[i1 + N / 2 - (N % 2 == 0)];
        end--;
      }
    } else {
      if (s1[i1] < s2[i2]) {
        s_r[i] = s2[i2];
        i2--;
        ++i;
      } else {
        s_r[end] = s2[i2 - N / 2 + (N % 2 == 0)];
        end--;
      }
    }
    x ^= 1;
    --N;
  }
  cout << s_r;
  return 0;
}
