using System;
using System.Collections.Generic;
using System.Linq;

namespace _1___Sudar_brojeva
{
    class Program
    {
        static void Main()
        {
            string x = Console.ReadLine();
            string y = Console.ReadLine();
            string resenje = String.Empty;

            List<char> ListX = new List<char>();
            ListX.AddRange(x);
            List<char> ListY = new List<char>();
            ListY.AddRange(y);

            if (ListX.Count > ListY.Count)
            {
                ListY.Reverse();
                while (ListX.Count > ListY.Count)
                    ListY.Add('x');
                ListY.Reverse();
            }
            else if (ListY.Count > ListX.Count)
            {
                ListX.Reverse();
                while (ListY.Count > ListX.Count)
                    ListX.Add('x');
                ListX.Reverse();
            }

            for (int i = 0; i < ListX.Count; i++)
            {
                if (ListX[i] == 'x')
                    resenje += ListY[i];
                else if (ListY[i] == 'x')
                    resenje += ListX[i];
                else if (ListX[i] == ListY[i])
                {
                    resenje += ListX[i];
                    resenje += ListX[i];
                }
                else
                    resenje += (int)ListX[i] > (int)ListY[i] ? ListX[i] : ListY[i];
            }

            Console.WriteLine(resenje);
        }
    }
}