#include <bits/stdc++.h>
using namespace std;
#pragma GCC optimize("Ofast")
const double PI = 3.1415926535897932384626433832;
int main() {
  ios::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
  string s, d;
  cin >> s >> d;
  int c = 0;
  for (int i = 0; i < s.size(); i++) {
    if (s[i] != d[i]) c++;
  }
  if (c % 2)
    cout << "impossible";
  else {
    string t = "";
    int flag = 0;
    for (int i = 0; i < s.size(); i++) {
      if (s[i] != d[i]) {
        if (flag == 0) {
          t += s[i];
          flag = 1;
        } else {
          t += d[i];
          flag = 0;
        }
      } else {
        t += s[i];
      }
    }
    cout << t;
  }
  return 0;
}
