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;
long long gcd(long long n1, long long n2) {
  if (n1 % n2 == 0) return n2;
  return gcd(n2, n1 % n2);
}
long long powmod(long long base, long long exponent) {
  long long ans = 1;
  while (exponent) {
    if (exponent & 1) ans = (ans * base) % 1000000007;
    base = (base * base) % 1000000007;
    exponent /= 2;
  }
  return ans;
}
int arr[1000005];
char ans[1000005];
int one[100], two[100];
int main() {
  string a, b;
  cin >> a >> b;
  for (int i = 0; i < a.length(); i++) {
    one[a[i] - 'a']++;
  }
  for (int i = 0; i < b.length(); i++) {
    two[b[i] - 'a']++;
  }
  int n = a.length();
  int ff = (n + 1) / 2;
  int ss = n - ff;
  bool flag2 = true;
  int first = 0, last = n - 1;
  int i = 0;
  for (i = 0; i < a.length(); i++) {
    if (i % 2 == 0) {
      int c;
      for (int j = 0; j < 26; j++) {
        if (one[j] > 0) {
          c = j;
          break;
        }
      }
      bool flag = true;
      for (int j = c + 1; j < 26; j++) {
        if (two[j] > 0) {
          flag = false;
        }
      }
      if (flag) {
        flag2 = true;
        break;
      } else {
        one[c]--;
        ans[first] = c + 'a';
        first++;
      }
      ff--;
    } else {
      int c = 0;
      for (int j = 0; j < 26; j++) {
        if (two[j] > 0) {
          c = j;
        }
      }
      bool flag = true;
      for (int j = 0; j < c; j++) {
        if (one[j] > 0) {
          flag = false;
        }
      }
      if (flag) {
        flag2 = true;
        break;
      } else {
        ans[first] = c + 'a';
        first++;
        two[c]--;
      }
      ss--;
    }
  }
  if (flag2) {
    for (; i < n; i++) {
      char c;
      if (i % 2 == 0) {
        int cnt = 0;
        for (int j = 0; j < 26; j++) {
          cnt += one[j];
          if (cnt >= ff) {
            c = j;
            break;
          }
        }
        one[c]--;
        ans[last] = c + 'a';
        last--;
        ff--;
      } else {
        int cnt = 0;
        for (int j = 25; j >= 0; j--) {
          cnt += two[j];
          if (cnt >= ss) {
            c = j;
            break;
          }
        }
        ans[last] = c + 'a';
        last--;
        two[c]--;
        ss--;
      }
    }
  }
  for (int i = 0; i < n; i++) cout << ans[i];
  return 0;
}
