#include <bits/stdc++.h>
using namespace std;
char ans[300005];
int main() {
  string oleg;
  string egor;
  cin >> oleg;
  cin >> egor;
  int n = oleg.length();
  sort(oleg.begin(), oleg.end());
  sort(egor.begin(), egor.end());
  int left_oleg, right_oleg;
  left_oleg = 0;
  right_oleg = n / 2 - !(n % 2);
  int left_egor, right_egor;
  right_egor = n - 1;
  left_egor = n / 2 + n % 2;
  int cnt = 0;
  int i = 0;
  int j = n - 1;
  while (cnt < n) {
    if (cnt == n - 1) {
      ans[i] = oleg[left_oleg];
      i++;
      left_oleg++;
      cnt++;
      break;
    } else if (oleg[left_oleg] < egor[right_egor]) {
      ans[i] = oleg[left_oleg];
      cnt++;
      left_oleg++;
      i++;
    } else {
      ans[j] = oleg[right_oleg];
      cnt++;
      right_oleg--;
      j--;
    }
    if (cnt == n - 1) {
      ans[i] = egor[right_egor];
      i++;
      cnt++;
      right_egor--;
      break;
    } else if (oleg[left_oleg] < egor[right_egor]) {
      ans[i] = egor[right_egor];
      i++;
      cnt++;
      right_egor--;
    } else {
      ans[j] = egor[left_egor];
      j--;
      cnt++;
      left_egor++;
    }
  }
  ans[n] = '\n';
  cout << ans;
  return 0;
}
