#include <bits/stdc++.h>
using namespace std;
const int maxn = 1e6 + 2;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
  char a[100009], b[100009], c[100009];
  int i, j, n, t, f = 1, ac = 0, bc = 0, eq, nq = 0;
  cin >> n >> t;
  cin >> a >> b;
  eq = n - t;
  for (i = 0; i < n; ++i) c[i] = '0';
  for (i = 0; i < n; ++i) {
    if (a[i] != b[i]) ++nq;
  }
  i = 0;
  while (eq && i < n) {
    if (a[i] == b[i]) {
      c[i] = a[i];
      --eq;
    }
    ++i;
  }
  if (eq > nq * 2) {
    cout << -1;
    return 0;
  }
  if (eq) {
    for (i = 0; i < n && eq; ++i) {
      if (a[i] != b[i]) {
        if (f == 1)
          c[i] = a[i], ++ac;
        else
          c[i] = b[i], ++bc;
        if (f == -1) --eq;
        f *= -1;
      }
    }
    if (ac != bc || eq) {
      cout << -1;
      return 0;
    }
  }
  for (i = 0; i < n; ++i) {
    if (c[i] == '0') {
      for (j = 'a'; j <= 'z'; ++j)
        if (a[i] != j && b[i] != j) c[i] = j;
    }
  }
  for (i = 0; i < n; ++i) cout << c[i];
}
