#include <iostream>
#include <algorithm>
using namespace std;
int main(int argc, char** argv) {
	ios_base::sync_with_stdio(false);
	
	string s1,s2;
	cin >>s1>>s2;
	int s1size=s1.size(),s2size=s2.size();
	reverse(s1.begin(),s1.end());
	reverse(s2.begin(),s2.end());
	if(s1size>s2size)
	{
		while(s1size!=s2size)
		{
			s2+='#';
			s2size++;
		}
	}
	else if(s2size>s1size)
	{
		while(s1size!=s2size)
		{
			s1+='#';
			s1size++;
		}
	}
	
	string s3="";
	
	for(int i=0;i<s1.size();i++)
	{
		if(s1[i]>s2[i])
		{
			s3+=s1[i];
		}
		else if(s2[i]>s1[i])
		{
			s3+=s2[i];
		}
		else
		{
			s3+=s1[i];
			s3+=s2[i];
		}
	}
	reverse(s3.begin(),s3.end());
	cout <<s3<<"\n";
	
	return 0;
}