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

bccdb
 z
 dfdeed
 aab
 y
 abac

import java.io.OutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.PrintWriter;
import java.util.Scanner;

/**
 * Built using CHelper plug-in
 * Actual solution is at the top
 */
public class Main {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        Scanner in = new Scanner(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
        TaskC solver = new TaskC();
        solver.solve(1, in, out);
        out.close();
    }

    static class TaskC {
        int len;

        public int[] readWord(Scanner in) {

            int[] res = new int[26];
            String s = in.next();
            len = s.length();

            for (int i = 0; i < s.length(); ++i)
                ++res[s.charAt(i) - 'a'];

            return res;
        }

        public void solve(int testNumber, Scanner in, PrintWriter out) {
            int[] a = readWord(in);
            int[] b = readWord(in);

            char[] res = new char[len];

            int left = 0, right = len - 1;
            for (int i = 0; i < len; ++i) {
                if (i % 2 == 0) {
                    int min = 0;
                    while (a[min] == 0) ++min;
                    int max = b.length - 1;
                    while (b[max] == 0) --max;
                    if (min < max) {
                        res[left++] = (char) ('a' + min);
                        --a[min];
                    } else {
                        int togo = (len - i - 1) / 2;
                        while (a[min] <= togo) {
                            togo -= a[min];
                            ++min;
                        }
                        res[right--] = (char) ('a' + min);
                    }
                } else {
                    int min = 0;
                    while (a[min] == 0) ++min;
                    int max = b.length - 1;
                    while (b[max] == 0) --max;
                    if (min < max) {
                        res[left++] = (char) ('a' + max);
                        --b[max];
                    } else {
                        int togo = (len - i - 1) / 2;
                        while (b[max] <= togo) {
                            togo -= b[max];
                            --max;
                        }
                        res[right--] = (char) ('a' + max);
                    }
                }
            }
            out.println(new String(res));
        }

    }
}

