#include <bits/stdc++.h>
using namespace std;
int main() {
  string s, t, l = "";
  long long x = 0;
  cin >> s;
  cin >> t;
  for (int i = 0; i < (int)(s.size()); i++)
    if (s[i] != t[i]) x++;
  long long i;
  if (x % 2 != 0)
    cout << "impossible";
  else {
    x = x / 2;
    for (i = 0; x != 0; i++) {
      if (s[i] != t[i]) {
        if (s[i] == '1')
          cout << '0';
        else
          cout << '1';
        x--;
      } else
        cout << s[i];
    }
    for (; i < s.size(); i++) {
      cout << s[i];
    }
  }
  return 0;
}
