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.IOException;
import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.io.InputStream;

/**
 * Built using CHelper plug-in
 * Actual solution is at the top
 *
 * @author orthodoxparadox
 */
public class Main {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        InputReader in = new InputReader(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, InputReader in, PrintWriter out) {
            String s = in.next();
            String t = in.next();
            int n = s.length();
            char[] oleg = s.toCharArray();
            char[] igor = t.toCharArray();
            Arrays.sort(oleg);
            Arrays.sort(igor);
            char[] res = new char[n];
            int x = 0;
            int y = n - 1;
            int fin = n - 1;
            int i = 0;
            int flip = 0;
            while (i <= fin) {
                if (flip == 0) {
                    if (oleg[x] > igor[y]) {
                        res[fin] = oleg[x];
                        x++;
                        fin--;
                    } else {
                        res[i] = oleg[x];
                        x++;
                        i++;
                    }
                } else {
                    if (igor[y] < oleg[x]) {
                        res[fin] = igor[y];
                        y--;
                        fin--;
                    } else {
                        res[i] = igor[y];
                        y--;
                        i++;
                    }
                }
                flip = 1 - flip;
            }
            out.print(new String(res));
        }

    }

    static class InputReader {
        public BufferedReader reader;
        public StringTokenizer tokenizer;

        public InputReader(InputStream stream) {
            reader = new BufferedReader(new InputStreamReader(stream), 32768);
            tokenizer = null;
        }

        public String next() {
            while (tokenizer == null || !tokenizer.hasMoreTokens()) {
                try {
                    tokenizer = new StringTokenizer(reader.readLine());
                } catch (IOException e) {
                    throw new RuntimeException(e);
                }
            }
            return tokenizer.nextToken();
        }

    }
}

