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 {
		Scanner sc=new Scanner();
		PrintWriter out=new PrintWriter(System.out);
		char []s=sc.next().toCharArray(),t=sc.next().toCharArray();
		Arrays.sort(s);
		Arrays.sort(t);
		int n=s.length;
		int idx1=0,idx2=n-1;
		char []ans=new char [n];
	
		// we know that player A will choose the smallest ceil(n/2) characters and they will be sorted
		// same for player B but for the largest floor(n/2)
		boolean turn=true;
		int cons=0;
		for(int i=0;i<n;) {
			if(cons==n/2 || idx1==(n+1)/2) {
				while(cons<n/2) {
					ans[i++]=t[idx2--];
					cons++;
				}
				while(idx1<(n+1)/2) {
					ans[i++]=s[idx1++];
					
				}
				break;
			}
			
			if(turn) {
				while(cons<n/2) {
					char c1=s[idx1],c2=t[idx2];
					if(c2<=c1) {
						ans[i++]=c2;
						cons++;
						idx2--;
					}
					else
					{
						ans[i++]=c1;
						idx1++;
						turn=false;
						break;
					}
				}
			}
			else {
				while(idx1<(n+1)/2) {
					char c1=s[idx1],c2=t[idx2];
					if(c1>=c2) {
						ans[i++]=c1;
						idx1++;
					}
					else {
						ans[i++]=c2;
						idx2--;
						cons++;
						turn=true;
						break;
					}
				}
				
			}
			
		}
		out.println(ans);
		out.close();

	}
	static class Scanner
	{
		BufferedReader br;
		StringTokenizer st;
		Scanner(){
			br=new BufferedReader(new InputStreamReader(System.in));
		}
		Scanner(String fileName) throws FileNotFoundException{
			br=new BufferedReader(new FileReader(fileName));
		}
		String next() throws IOException {
			while(st==null || !st.hasMoreTokens())
				st=new StringTokenizer(br.readLine());
			return st.nextToken();
		}
		String nextLine() throws IOException {
			return br.readLine();
		}
		int nextInt() throws IOException{
			return Integer.parseInt(next());
		}
		long nextLong()  throws NumberFormatException, IOException {
			return Long.parseLong(next());
		}
		double nextDouble() throws NumberFormatException, IOException {
			return Double.parseDouble(next());
		}
	}
}
