#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  string one, two;
  cin >> one;
  cin >> two;
  n = one.length();
  string final = "";
  int counter = 0;
  for (int i = 0, _i = (n); i < _i; ++i) {
    if (one[i] != two[i]) counter++;
  }
  if (counter % 2 != 0)
    cout << "impossible\n";
  else {
    counter = 0;
    for (int i = 0, _i = (n); i < _i; ++i) {
      if (one[i] == two[i]) {
        final += one[i];
      } else {
        if (counter % 2 == 0)
          final += one[i];
        else
          final += two[i];
        counter++;
      }
    }
    cout << final << endl;
  }
  return 0;
}
