#include <bits/stdc++.h>
using namespace std;
const long long mod = 1e9 + 7;
const long long add = 200005;
long long n, m, k = 0, a[2000005], b[200005], vis[200005] = {0},
                red[200005] = {0};
set<long long> st, st1;
map<pair<long long, long long>, long long> mp;
string s1, s2, s3 = "";
vector<long long> vv;
vector<pair<pair<long long, long long>, long long> > v;
int main() {
  ios::sync_with_stdio(false);
  cin.tie(NULL);
  char c1 = 'G', c2 = 'B';
  long long i, j, x, y, ans = 0, mx = 0, nbs = 0, nbi = 0, nb0 = 0, l, r,
                        res = 0, ok = 0, p, sm = 0;
  set<long long>::iterator it;
  cin >> n >> m;
  cin >> s1 >> s2;
  for (i = 0; i < n; i++) {
    if (s1[i] != s2[i]) nb0++;
  }
  if (nb0 <= m) {
    for (i = 0; i < n; i++) {
      if (s1[i] == s2[i])
        s3 += s1[i];
      else
        for (j = 97; j <= 122; j++)
          if (j != s1[i] && j != s2[i]) {
            res++;
            s3 += (char)j;
            break;
          }
    }
    res = m - res;
    while (res) {
      for (i = 0; i < n; i++) {
        if (s1[i] == s2[i]) {
          res--;
          for (j = 97; j <= 122; j++)
            if (j != s1[i] && j != s2[i]) {
              s3[i] = (char)j;
              break;
            }
          if (!res) break;
        }
      }
    }
    return cout << s3, 0;
  }
  long long mm = (nb0 / 2) + (nb0 & 1);
  if (m < mm) return cout << "-1", 0;
  long long rem, cur, remx = 0, flag = 0;
  for (rem = 1; rem <= nb0; rem++) {
    if (((nb0 - rem) % 2 == 0) && remx < (rem + (nb0 - rem) / 2) &&
        (rem + (nb0 - rem) / 2) <= m)
      remx = rem;
  }
  cur = remx + (nb0 - remx) / 2;
  rem = remx;
  for (i = 0; i < n; i++) s3 += '#';
  for (i = 0; i < n; i++) {
    if (s1[i] == s2[i]) {
      s3[i] = s1[i];
      continue;
    }
    if (rem) {
      rem--;
      for (j = 97; j <= 122; j++) {
        if (j != s1[i] && j != s2[i]) {
          s3[i] = (char)j;
          break;
        }
      }
      continue;
    }
    if (!flag)
      s3[i] = s1[i], flag ^= 1;
    else
      s3[i] = s2[i], flag ^= 1;
  }
  if (cur < m)
    for (i = 0; i < n; i++) {
      if (s1[i] == s2[i]) {
        cur++;
        for (j = 97; j <= 122; j++) {
          if (j != s1[i] && j != s2[i]) {
            s3[i] = (char)j;
            break;
          }
        }
        if (m == cur) break;
      }
    }
  cout << s3;
}
