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

bccdb
 z
 dfdeed
 aab
 y
 abac

import java.io.*;
import java.util.*;

public class C{
	public static void main(String[] args) throws IOException {
		// br = new BufferedReader(new FileReader(".in"));
		// out = new PrintWriter(new FileWriter(".out"));
		//new Thread(null, new (), "peepee", 1<<28).start();
		
		String s =read();
		String s2 = read();
		List<Character> a1 = new ArrayList<Character>();
		List<Character> a2 = new ArrayList<Character>();
		for (char c: s.toCharArray()) a1.add(c);
		for (char c: s2.toCharArray()) a2.add(c);
		int sizea1 = (s.length()+1)/2;
		int sizea2 = s.length()/2;
		Collections.sort(a1);
		Collections.sort(a2, Collections.reverseOrder());
		while (a1.size() > sizea1) a1.remove(a1.size()-1);
		while (a2.size() > sizea2) a2.remove(a2.size()-1);
		Collections.sort(a1, Collections.reverseOrder());
		Collections.sort(a2);
		ArrayDeque<Character> ra1 = new ArrayDeque<Character>();
		ArrayDeque<Character> ra2 = new ArrayDeque<Character>();
		// Ordered from best in the last position to worst in the first position.
		for (char x: a1) ra1.add(x);
		for (char x: a2) ra2.add(x); 
		char[] c = new char[s2.length()];
		int fp = 0;
		int bp = s2.length()-1;
		int turn = 0;
		while (turn < s.length()) {
			if (ra1.isEmpty()) {
				c[fp]=ra2.poll();
				break;
			}
			else if (ra2.isEmpty()) {
				c[fp]=ra1.poll();
				break;
			}
			int comp = ra1.peekLast() - ra2.peekLast();
			//System.out.println(c1 + " " + c2);
			if (comp < 0) {
				if (turn % 2 ==0) {
					c[fp] = ra1.pollLast();
				}
				else {
					c[fp] = ra2.pollLast();
				}
				fp++;
			}
			else if (comp >= 0){
				// Oleg wants to switch it up?
				// He wants to now start placing from the back.
				// Same with the other dude.
				if (turn % 2 == 0) {
					c[bp] = ra1.pollFirst();
				}
				else {
					c[bp] = ra2.pollFirst();
				}
				bp--;
			}
			else {
				if (turn % 2 == 0) {
					c[bp--] = ra1.pollLast();
				}
				else {
					c[fp++] = ra2.pollFirst();
				}
			}
			turn++;
		}
		for (char ch: c) out.print(ch);
		
		out.println();
		out.close();
	}
	
	static BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
	static PrintWriter out = new PrintWriter(new BufferedOutputStream(System.out));
	static StringTokenizer st = new StringTokenizer("");
	static String read() throws IOException{return st.hasMoreTokens() ? st.nextToken():(st = new StringTokenizer(br.readLine())).nextToken();}
	static int readInt() throws IOException{return Integer.parseInt(read());}
	static long readLong() throws IOException{return Long.parseLong(read());}
	static double readDouble() throws IOException{return Double.parseDouble(read());}
	
}