#include using namespace std; void fast_io() { ios_base::sync_with_stdio(false); cin.tie(nullptr); } int main() { fast_io(); string a, b; cin >> a >> b; int a_num = 0, b_num = 0; for (int i = 0; i < a.size(); i++) { a_num = 2 * a_num + (a[i] - '0'); } for (int i = 0; i < b.size(); i++) { b_num = 2 * b_num + (b[i] - '0'); } cout << (a_num ^ b_num) << endl; }