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 MAX_CHAR = 26;
void stringsort(string &s) {
  int count[MAX_CHAR] = {0};
  int size = s.length();
  for (int i = 0; i < size; i++) {
    count[s[i] - 'a']++;
  }
  for (int i = 0, j = 0; i < MAX_CHAR; i++) {
    int x = count[i];
    while (x--) {
      s[j] = (char)('a' + i);
      j++;
    }
  }
}
int main() {
  string oleg, igor;
  cin >> oleg >> igor;
  int n = oleg.length();
  stringsort(oleg);
  stringsort(igor);
  string s, sr;
  int itoleg = 0, itigor = n - 1;
  int alt = 1, i = 0;
  for (; i < n && oleg[itoleg] < igor[itigor]; i++) {
    if (alt == 1) {
      s.push_back(oleg[itoleg]);
      itoleg++;
    }
    if (alt == -1) {
      s.push_back(igor[itigor]);
      itigor--;
    }
    alt *= -1;
  }
  if (n % 2 == 0) {
    itoleg = n / 2 - 1;
    itigor = n / 2;
  } else {
    itoleg = n / 2;
    itigor = n / 2 + 1;
  }
  for (; i < n; i++) {
    if (alt == 1) {
      sr.push_back(oleg[itoleg]);
      itoleg--;
    }
    if (alt == -1) {
      sr.push_back(igor[itigor]);
      itigor++;
    }
    alt *= -1;
  }
  int x = sr.length();
  for (int j = x - 1; j >= 0; j--) {
    s.push_back(sr[j]);
  }
  cout << s;
  return 0;
}
