#include #include #include #include #include #include #include #include #include const long long INF = 1e6+7; const long long MOD = 1e9+7; const double PI=acos(-1); using namespace std; int main(){ int a,c; cin >> a >> c; int b=a xor c; cout << b << endl; return 0; }