#include using namespace std; int main(){ int x, y; cin >> x >> y; cout << min(min(x, y), x ^ y) << endl; }