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

bccdb
 z
 dfdeed
 aab
 y
 abac

import java.lang.*;
import java.util.Scanner;
import java.util.Arrays;

public class Main
{
    public static void main(String args[])
    {
        Scanner sc = new Scanner(System.in);
        String s1 = sc.next();
        String s2 = sc.next();
        int n = s1.length();
        char a[] = s1.toCharArray();
        char b[] = s2.toCharArray();
        
        Arrays.sort(a);
        Arrays.sort(b);
        char c[] = new char[n]; int m=0; int cl=n-1; int j=n-1; int f=0;
        int i=0; int k = (int)Math.ceil(n*1.0/2); int al=k-1; int bl=n-(n/2);
        while(f<k)
        {
            if(f<n/2)
            {
                if(a[i]<b[j])
                {
                    c[m++]=a[i++]; 
                    if(b[j]>a[i])
                        c[m++]=b[j--];
                    else
                        c[cl--]=b[bl++];
                }
                else
                {
                    c[cl--]=a[al--];
                    if(b[j]>a[i])
                        c[m++]=b[j--];
                    else
                        c[cl--]=b[bl++];
                }
            }
            if(f==n/2){
                c[m++]=a[i++];
                 break;
            }
            f++;
        }
        for(m=0;m<n;m++)
            System.out.print(c[m]);
        
    }
}