#include <bits/stdc++.h>
using namespace std;
int main() {
  std::ios::sync_with_stdio(false);
  string s, t;
  cin >> s >> t;
  int i, j, len = s.length(), diff = 0;
  for (i = 0; i < len; i++) {
    if (s[i] != t[i]) {
      diff++;
    }
  }
  if (diff % 2 != 0) {
    cout << "impossible";
    return 0;
  }
  j = 0;
  for (i = 0; i < len; i++) {
    if (s[i] == t[i]) {
      cout << s[i];
      continue;
    }
    if (j % 2) {
      cout << s[i];
    } else {
      cout << t[i];
    }
    j++;
  }
  return 0;
}
