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

bccdb
 z
 dfdeed
 aab
 y
 abac

import java.util.Scanner;

public class Solution {
	private static int len;
	
	public static int[] readWord(Scanner sc) {
		int[] res = new int[26];
		String s = sc.nextLine();
		len = s.length();
		for (int i = 0; i < s.length(); i++) {
			++res[s.charAt(i) - 'a'];
		}
		return res;
	}
	
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		
		int[] a = readWord(sc);
		int[] b = readWord(sc);
		
		char[] res = new char[len];
		int left = 0;
		int 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) {
					--a[min];
					res[left++] = (char) ('a' + min);
				} else {
					int togo = (len - i) / 2;
					while (a[min] < togo) {
						togo -= a[min];
						++min;
					}
					--a[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) {
					--b[max];
					res[left++] = (char) ('a' + max);
				} else {
					int togo = (len - i) / 2;
					while (b[max] < togo) {
						togo -= b[max];
						--max;
					}
					--b[max];
					res[right--] = (char) ('a' + max);
				}
			}
		}
		System.out.println(new String(res));
	}
}
