#include <bits/stdc++.h>
using namespace std;
char dich(char a) {
  if (a == '1')
    return '0';
  else
    return '1';
}
int main() {
  string s, ss, res;
  cin >> s >> ss;
  int i, j = 0;
  res = s;
  for (i = 0; i < s.size(); i++) {
    if (s[i] != ss[i]) j++;
  }
  if (j % 2 != 0)
    cout << "impossible";
  else {
    j = j / 2;
    for (i = 0; i < s.size(); i++) {
      if (s[i] != ss[i]) {
        res[i] = dich(s[i]);
        j--;
        if (j == 0) break;
      }
    }
    cout << res << endl;
  }
}
