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

bccdb
 z
 dfdeed
 aab
 y
 abac

a=input()
b=input()
c=''
a=''.join(sorted(a))
b=''.join(sorted(b,reverse=True))
i,j,k=0,0,0
if(a[i]<=b[j]):
    cond1=True
else:
    cond1=False
while(k<len(a)):
   if cond1: 
       if(k%2==0):
           c+=a[i]
           i+=1
       else:
           c+=b[j]
           j+=1
       k+=1
   else:
       if(k%2==0):
           c+=b[j]
           j+=1
       else:
           c+=a[i]
           i+=1
       k+=1
print(c)
        