#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, m;
  cin >> n >> m;
  string str, str1, str2(n, '0');
  cin >> str >> str1;
  if (m == 0) {
    if (str == str1) {
      cout << str << endl;
    } else
      cout << -1 << endl;
    return 0;
  }
  int cnt = 0;
  for (int i = 0; i < n; i++) {
    if (str[i] == str1[i])
      str2[i] = str[i];
    else {
      if (str[i] != 'm' && str1[i] != 'm')
        str2[i] = 'm';
      else if (str[i] != 'n' && str1[i] != 'n')
        str2[i] = 'n';
      else
        str2[i] = 'p';
      cnt++;
    }
  }
  if (cnt == m)
    cout << str2 << endl;
  else if (cnt > m) {
    int c = 0;
    for (int i = 0; i < n; i++) {
      if (str[i] != str1[i]) {
        c++;
        if (c % 2 == 1) {
          str2[i] = str[i];
        } else {
          str2[i] = str1[i];
          cnt--;
        }
        if (cnt == m) break;
      }
    }
    if (cnt == m)
      cout << str2 << endl;
    else
      cout << -1 << endl;
  } else {
    for (int i = 0; i < n; i++) {
      if (str[i] == str1[i]) {
        if (str[i] != 'm')
          str2[i] = 'm';
        else
          str2[i] = 'n';
        cnt++;
      }
      if (cnt == m) break;
    }
    cout << str2 << endl;
  }
  return 0;
}
