#include <bits/stdc++.h>

using namespace std;

#define ll long long
const int INF=1e9;
const ll LINF=1e18,MOD=1e9+7,LOG=17;
const int SQ=317;
#define fi first
#define se second
#define pii pair<int,int>
#define pll pair<long long,long long>
#define mid ((l+r)/2)
#define sz(a) (int((a).size()))
#define all(a) a.begin(),a.end()
#define endl "\n"
#define PRINT(x) cerr<<#x<<'='<<x<<endl;
#define pb push_back
#define PRINTvec(niz) {cerr<<#niz<<"="; for(auto _i:niz) cerr<<_i<<" "; cerr<<endl; }

void Md(ll& x){
    if(x>=MOD) x%=MOD;
}

void Solve(){
    string S1,S2; cin>>S1>>S2;
    if(sz(S1)>sz(S2)) swap(S1,S2);
    reverse(all(S1));
    while(sz(S1)!=sz(S2)){
        S1.pb('/');
    }
    reverse(all(S1));
    string res="";
    for(int i=0;i<sz(S2);i++){
        if(S1[i]-'0'==S2[i]-'0'){
            res.pb(S1[i]);
            res.pb(S2[i]);
        }
        else if(S1[i]-'0'>S2[i]-'0') res.pb(S1[i]);
        else res.pb(S2[i]);
    }
    cout<<res<<endl;
}

int main(){
    ios::sync_with_stdio(false);
    cin.tie(0);
    cout.tie(0);
    int t; t=1;
    //cin>>t;;
    while(t--){
        Solve();
    }
    return 0;
}