#include <bits/stdc++.h>
#define REP(i,a,b) for(i=a;i<b;i++)
#define rep(i,n) REP(i,0,n)
#define ll long long
#define ull unsigned ll
using namespace std;
int hex_to_int(char c){
        int first = c / 16 - 3;
        int second = c % 16;
        int result = first*10 + second;
        if(result > 9) result--;
        return result;
}

int hex_to_ascii(char c, char d){
        int high = hex_to_int(c) * 16;
        int low = hex_to_int(d);
        return high+low;
}
int main()
{
	string a,b,c;
    cin>>a>>b;
    int lb=b.size(),la=a.size(),i;
    for(i=0;i<lb;i+=2)
    {
        if(islower(b[i]))
            b[i]=toupper(b[i]);
        if(islower(b[i+1]))
            b[i+1]=toupper(b[i+1]);
        
        c[i]=hex_to_ascii(b[i],b[i+1])^a[(i/2)%la];
        cout<<c[i];
    }
    return 0;
}