#include <bits/stdc++.h>
using namespace std;
int main() {
  string s, t, p;
  cin >> s >> t;
  auto n = s.length();
  int d = 0;
  for (int i = 0; i < n; i++) {
    if (s[i] != t[i]) {
      d++;
    }
  }
  if (d & 1) {
    cout << "impossible" << endl;
  } else {
    string p(n, '0');
    int sd = 0, td = 0;
    for (int i = 0; i < n; i++) {
      if (s[i] != t[i]) {
        if (sd < td) {
          p[i] = t[i];
          sd++;
        } else {
          p[i] = s[i];
          td++;
        }
      }
    }
    cout << p << endl;
  }
}
