bcdef
abbbc
 z
y
 reddit
abcdef
 abc
aaa
 y
z
 cbxz
aaaa

bccdb
 z
 dfdeed
 aab
 y
 abac

#include <bits/stdc++.h>
template <typename T>
void scan(T &x) {
  x = 0;
  bool _ = 0;
  T c = getchar();
  _ = c == 45;
  c = _ ? getchar() : c;
  while (c < 48 || c > 57) c = getchar();
  for (; c < 48 || c > 57; c = getchar())
    ;
  for (; c > 47 && c < 58; c = getchar()) x = (x << 3) + (x << 1) + (c & 15);
  x = _ ? -x : x;
}
template <typename T>
void printn(T n) {
  std::cout << n;
}
template <typename First, typename... Ints>
void scan(First &arg, Ints &...rest) {
  scan(arg);
  scan(rest...);
}
template <typename T>
void print(T n) {
  printn(n);
  putchar(10);
}
template <typename First, typename... Ints>
void print(First arg, Ints... rest) {
  printn(arg);
  putchar(32);
  print(rest...);
}
using namespace std;
const int MM = 3e5 + 5;
char a[MM], b[MM], c[MM];
int n, l, r, t, al, ar, bl, br, rem;
int main() {
  scanf("%s %s", a, b);
  n = strlen(a);
  sort(a, a + n);
  sort(b, b + n);
  l = al = bl = 0, r = ar = br = n - 1;
  int fs = (n + 1) / 2, ss = n - fs;
  ar = fs - 1;
  bl = n - ss;
  while (l <= r) {
    if (!t) {
      if (a[al] < b[br]) {
        c[l++] = a[al++];
      } else {
        c[r--] = a[ar--];
      }
    } else {
      if (b[br] > a[al]) {
        c[l++] = b[br--];
      } else {
        c[r--] = b[bl++];
      }
    }
    t ^= 1;
  }
  printf("%s\n", c);
  return 0;
}
