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

bccdb
 z
 dfdeed
 aab
 y
 abac

a = sorted(input())
b = sorted(input())
l = len(a)
result = ""

if a[0] > b[-1]:
    ai = (l + 1) // 2 - 1
    bi = l - l // 2
    result += a[ai]
    ai -= 1
    while len(result) < len(a):
        result = b[bi] + result
        bi += 1
        if len(result) == len(a):
            break
        result = a[ai] + result
        ai -= 1
else:
    ai = 0
    bi = l - 1
    while len(result) < len(a):
        result += a[ai]
        ai += 1
        if len(result) == len(a):
            break
        result += b[bi]
        bi -= 1
print(result)