#include <bits/stdc++.h>
using namespace std;
const int maxn = 1e5 + 10;
char s[maxn], t[maxn], p[maxn];
int main() {
  gets(s);
  gets(t);
  memset(p, '\0', sizeof(p));
  int n = strlen(s), usa = 0;
  for (int i = 0; i < n; ++i) {
    if (s[i] == t[i])
      p[i] = s[i];
    else
      usa++;
  }
  if (usa & 1)
    puts("impossible");
  else {
    bool ok = true;
    for (int i = 0; i < n; ++i) {
      if (s[i] != t[i]) {
        if (ok) {
          p[i] = s[i];
          ok = false;
        } else {
          p[i] = t[i];
          ok = true;
        }
      }
    }
    puts(p);
  }
  return 0;
}
