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.Arrays;
import java.util.StringTokenizer;
import java.io.BufferedReader;
import java.io.FileReader;
import java.io.InputStreamReader;
import java.io.InputStream;

/**
 * Built using CHelper plug-in
 * Actual solution is at the top
 *
 * @author Omar Yasser
 */
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 {
        public void solve(int testNumber, Scanner sc, PrintWriter out) {
            char[] a1 = sc.next().toCharArray();
            char[] a2 = sc.next().toCharArray();
            int n = a1.length;
            Character a11[] = new Character[n], a22[] = new Character[n];
            for (int i = 0; i < n; i++) {
                a11[i] = a1[i];
                a22[i] = a2[i];
            }

            Arrays.sort(a11);
            Arrays.sort(a22);

            int len1 = n % 2 == 0 ? n / 2 : n / 2 + 1, len2 = n / 2;

            int cnt1[] = new int[26], cnt2[] = new int[26];
            for (int i = 0; i < len1; i++) cnt1[a11[i] - 'a']++;
            for (int i = 0; i < len2; i++) cnt2[a22[n - i - 1] - 'a']++;

            int[] res = new int[n];
            int left = 0, right = n - 1;
            int parity = 0;
            for (int i = 0; i < n; i++) {
                if ((parity & 1) == 0) {
                    boolean allLessOrEqual = true;
                    int first = 0, last = 0;
                    for (int j = 0; j < 26; j++) {
                        if (cnt1[j] != 0) {
                            first = j;
                            break;
                        }
                    }
                    for (int j = 25; j >= 0; j--) {
                        if (cnt1[j] != 0) {
                            last = j;
                            break;
                        }
                    }
                    for (int j = 0; j < 26; j++) {
                        if (cnt2[j] != 0) {
                            allLessOrEqual &= j <= first;
                        }
                    }

                    if (allLessOrEqual) {
                        res[right--] = last;
                        cnt1[last]--;
                    } else {
                        res[left++] = first;
                        cnt1[first]--;
                    }
                } else {
                    int bigger = 0, smaller = 0;
                    boolean allBiggerOrEqual = true;
                    for (int j = 0; j < 26; j++) {
                        if (cnt2[j] != 0) {
                            smaller = j;
                            break;
                        }
                    }
                    for (int j = 25; j >= 0; j--) {
                        if (cnt2[j] != 0) {
                            bigger = j;
                            break;
                        }
                    }
                    for (int j = 0; j < 26; j++) {
                        if (cnt1[j] != 0) {
                            allBiggerOrEqual &= j >= bigger;
                        }
                    }

                    if (allBiggerOrEqual) {
                        res[right--] = smaller;
                        cnt2[smaller]--;
                    } else {
                        res[left++] = bigger;
                        cnt2[bigger]--;
                    }
                }
                parity = 1 - parity;
            }

            for (int i = 0; i < n; i++)
                out.print((char) (res[i] + 'a'));
            out.println();
        }

    }

    static class Scanner {
        StringTokenizer st;
        BufferedReader br;

        public Scanner(InputStream s) {
            br = new BufferedReader(new InputStreamReader(s));
        }

        public Scanner(FileReader f) {
            br = new BufferedReader(f);
        }

        public String next() {
            while (st == null || !st.hasMoreTokens())
                try {
                    st = new StringTokenizer(br.readLine());
                } catch (Exception e) {
                }
            return st.nextToken();
        }

    }
}

