Marina loves strings of the same length and Vasya loves when there is a third string, different from them in exactly t characters. Help Vasya find at least one such string.

More formally, you are given two strings s_1, s_2 of length n and number t. Let's denote as f(a, b) the number of characters in which strings a and b are different. Then your task will be to find any string s_3 of length n, such that f(s_1, s_3) = f(s_2, s_3) = t. If there is no such string, print  - 1.


-----Input-----

The first line contains two integers n and t (1 ≤ n ≤ 10^5, 0 ≤ t ≤ n).

The second line contains string s_1 of length n, consisting of lowercase English letters.

The third line contain string s_2 of length n, consisting of lowercase English letters.


-----Output-----

Print a string of length n, differing from string s_1 and from s_2 in exactly t characters. Your string should consist only from lowercase English letters. If such string doesn't exist, print -1.


-----Examples-----
Input
3 2
abc
xyc

Output
ayd
Input
1 0
c
b

Output
-1

Difficulty: MEDIUM_HARD
Tags: Greedy algorithms

String algorithms

Constructive algorithms
Skill types: Greedy algorithms

Starter code:

Solutions:
import sys
(n, t) = [int(i) for i in input().split()]
s1 = input()
s2 = input()
common = 0
diff = 0
for i in range(n):
	if s1[i] == s2[i]:
		common += 1
	else:
		diff += 1
chars = 'abc'
ans = []
if common >= n - t:
	unc_common = n - t
	for i in range(n):
		if s1[i] == s2[i] and unc_common > 0:
			ans.append(s1[i])
			unc_common -= 1
		else:
			for char in chars:
				if char != s1[i] and char != s2[i]:
					ans.append(char)
					break
	print(''.join(ans))
else:
	unch = n - t - common
	unch1 = 0
	unch2 = 0
	if 2 * unch <= diff:
		for i in range(n):
			if s1[i] == s2[i]:
				ans.append(s1[i])
			elif unch1 < unch:
				ans.append(s1[i])
				unch1 += 1
			elif unch2 < unch:
				ans.append(s2[i])
				unch2 += 1
			else:
				for char in chars:
					if char != s1[i] and char != s2[i]:
						ans.append(char)
						break
		print(''.join(ans))
	else:
		print(-1)


import collections, itertools, fractions, functools, heapq, math, queue, copy

def other(a, b):
	for c in 'abc':
		if c != a and c != b:
			return c

def solve():
	(n, t) = map(int, input().split())
	s1 = list(input())
	s2 = list(input())
	dif = sum((1 for (a, b) in zip(s1, s2) if a != b))
	if dif > 2 * t:
		return -1
	s = []
	if dif <= t:
		for (a, b) in zip(s1, s2):
			if a == b:
				if dif < t:
					dif += 1
					s.append(other(a, b))
				else:
					s.append(a)
			else:
				s.append(other(a, b))
	else:
		diff1 = dif
		diff2 = dif
		for (a, b) in zip(s1, s2):
			if a == b:
				s.append(a)
				continue
			if diff1 > t:
				s.append(b)
				diff1 -= 1
				continue
			if diff2 > t:
				s.append(a)
				diff2 -= 1
				continue
			s.append(other(a, b))
	return str.join('', s)
print(solve())


def otherChar(x, y):
	for c in ('a', 'b', 'c'):
		if c != x and c != y:
			return c

def solve(a, b, t):
	n = len(a)
	e = sum((1 for i in range(n) if a[i] == b[i]))
	d = n - e
	for x in range(0, n + 1):
		if d - x + x // 2 <= t and x % 2 == 0:
			break
	if not (d - x + x // 2 <= t and x % 2 == 0):
		return -1
	w = d - x
	y = t - (d - x + x // 2)
	z = e - y
	if z < 0:
		return -1
	c = len(a) * [0]
	j = 0
	for i in range(n):
		if a[i] != b[i]:
			if w > 0:
				c[i] = otherChar(a[i], b[i])
				w -= 1
			else:
				c[i] = a[i] if j % 2 else b[i]
				x -= 1
			j += 1
		elif y > 0:
			c[i] = otherChar(a[i], b[i])
			y -= 1
		else:
			c[i] = a[i]
			z -= 1
	if not w == x == y == z == 0:
		return -1
	return ''.join(map(str, c))

def check(a, b, t, c):
	assert sum((1 for i in range(len(a)) if a[i] != c[i])) == t
	assert sum((1 for i in range(len(a)) if b[i] != c[i])) == t
(_, t) = map(int, input().split())
a = input()
b = input()
print(solve(a, b, t))


def diffchar(a, b):
	for i in range(26):
		c = chr(ord('a') + i)
		if c != a and c != b:
			return c
while True:
	try:
		(n, t) = map(int, input().split())
		(a, b) = (input() for _ in range(2))
	except:
		raise SystemExit
	same = [i for i in range(n) if a[i] == b[i]]
	diff = [i for i in range(n) if a[i] != b[i]]
	if 2 * t < len(diff):
		print(-1)
		continue
	(scnt, dcnt) = (n - t, t)
	res = ['.'] * n
	for si in same:
		if scnt == 0:
			break
		res[si] = a[si]
		scnt -= 1
	if scnt > 0:
		for (i, di) in enumerate(diff):
			if scnt == 0:
				break
			res[di] = a[di] if i % 2 == 0 else b[di]
			scnt -= 0.5
	for i in range(n):
		if res[i] == '.':
			res[i] = diffchar(a[i], b[i])
	print(''.join(res))


(n, t) = map(int, input().split())
s = set('qwertyuioplkjhgfdsazxcvbnm')
s1 = input()
s2 = input()
k1 = k2 = 0
for i in range(n):
	if s1[i] == s2[i]:
		k1 += 1
	else:
		k2 += 1
if t < k2 // 2 + k2 % 2:
	print(-1)
else:
	t -= k2 % 2
	k2 //= 2
	while t > k2 and k2 > 0:
		t -= 2
		k2 -= 1
	if k2 == 0 and t > k1:
		print(-1)
	else:
		if k2 == 0:
			k1 = t
		else:
			k1 = 0
		k3 = k2
		for i in range(n):
			if s1[i] == s2[i]:
				ss = s - {s1[i]}
				if k1 > 0:
					print(ss.pop(), end='')
					k1 -= 1
				else:
					print(s1[i], end='')
			else:
				ss = s - {s1[i], s2[i]}
				if k3 > k2:
					print(s1[i], end='')
					k3 -= 1
				elif k2 > 0:
					print(s2[i], end='')
					k2 -= 1
				else:
					print(ss.pop(), end='')


from collections import defaultdict

def mp():
	return map(int, input().split())

def lt():
	return list(map(int, input().split()))

def pt(x):
	print(x)

def ip():
	return input()

def it():
	return int(input())

def sl(x):
	return [t for t in x]

def spl(x):
	return x.split()

def aj(liste, item):
	liste.append(item)

def bin(x):
	return '{0:b}'.format(x)

def printlist(l):
	print(' '.join([str(x) for x in l]))

def listring(l):
	return ''.join([str(x) for x in l])
(n, t) = mp()
a = ip()
b = ip()
L = sum([a[i] != b[i] for i in range(n)])
if L > 2 * t:
	print(-1)
	exit()
result = ''
if L <= t:
	m = 0
	for i in range(n):
		if a[i] != b[i]:
			(p, q) = (ord(a[i]), ord(b[i]))
			c = q
			while c == p or c == q:
				c += 1
				if c == 123:
					c = 97
			result += chr(c)
		elif m < t - L:
			(p, q) = (ord(a[i]), ord(b[i]))
			c = q
			while c == p or c == q:
				c += 1
				if c == 123:
					c = 97
			result += chr(c)
			m += 1
		else:
			result += b[i]
else:
	u = L - t
	m = 0
	for i in range(n):
		if a[i] != b[i]:
			if m < 2 * u:
				if m % 2 == 0:
					result += a[i]
				else:
					result += b[i]
				m += 1
			else:
				(p, q) = (ord(a[i]), ord(b[i]))
				c = q
				while c == p or c == q:
					c += 1
					if c == 123:
						c = 97
				result += chr(c)
		else:
			result += b[i]
print(result)


(n, t) = map(int, input().split())
(a, b) = (input(), input())
ans = []
s = d = 0
for (i, j) in zip(a, b):
	if i == j:
		s += 1
	else:
		d += 1
if t < (d + 1) // 2:
	print(-1)
	exit()
x = min(n - t, s)
y = z = max(n - t - s, 0)

def f(a, b):
	for i in range(97, 123):
		if chr(i) not in [a, b]:
			return chr(i)
for i in range(n):
	if a[i] == b[i]:
		if x:
			ans.append(a[i])
			x -= 1
		else:
			ans.append(f(a[i], b[i]))
	elif y:
		ans.append(a[i])
		y -= 1
	elif z:
		ans.append(b[i])
		z -= 1
	else:
		ans.append(f(a[i], b[i]))
print(''.join(ans))


from math import ceil

def s(c1, c2):
	if c2 < c1:
		(c1, c2) = (c2, c1)
	if c1 == 'a':
		if c2 == 'b':
			return 'c'
		else:
			return 'b'
	else:
		return 'a'
(n, t) = [int(x) for x in input().split()]
(s1, s2) = (input(), input())
(cdiff, csame) = ([], [])
for (i, c1, c2) in zip(range(n), s1, s2):
	if c1 == c2:
		csame.append(i)
	else:
		cdiff.append(i)
out = [''] * n
d = n - t - len(csame)
if n - t <= len(csame):
	for i in csame[:n - t]:
		out[i] = s1[i]
	for i in range(n):
		if out[i] == '':
			out[i] = s(s1[i], s2[i])
	print(''.join(out))
elif len(cdiff) >= 2 * d:
	for i in csame[:n - t]:
		out[i] = s1[i]
	for i in cdiff[:d]:
		out[i] = s1[i]
	for i in cdiff[d:2 * d]:
		out[i] = s2[i]
	for i in cdiff[2 * d:]:
		out[i] = s(s1[i], s2[i])
	print(''.join(out))
else:
	print(-1)


(n, t) = [int(i) for i in input().split()]
s1 = input()
s2 = input()
same = 0
for i in range(n):
	if s1[i] is s2[i]:
		same += 1
diff = n - same
if t * 2 < diff:
	print(-1)
	exit()
if t * 2 == diff:
	f1 = t
	f2 = t
	s3 = ''
	for i in range(n):
		if s1[i] == s2[i]:
			s3 = s3 + s1[i]
		elif f1 > 0:
			s3 = s3 + s1[i]
			f1 -= 1
		else:
			s3 = s3 + s2[i]
	print(s3)
	exit()
oth = max(0, t - diff)
f1 = max(0, diff - t)
f2 = max(0, diff - t)
s3 = ''
for i in range(n):
	if s1[i] == s2[i]:
		if oth > 0:
			if s1[i] == 'a':
				s3 = s3 + 'b'
			else:
				s3 = s3 + 'a'
			oth -= 1
		else:
			s3 += s1[i]
	elif f1 > 0:
		s3 += s2[i]
		f1 -= 1
	elif f2 > 0:
		s3 += s1[i]
		f2 -= 1
	elif 'a' not in [s1[i], s2[i]]:
		s3 = s3 + 'a'
	elif 'b' not in [s1[i], s2[i]]:
		s3 = s3 + 'b'
	else:
		s3 = s3 + 'c'
print(s3)


def read_numbers():
	return list(map(int, input().split()))

def get_other_char(a, b):
	for c in 'abc':
		if c != a and c != b:
			return c
(n, t) = read_numbers()
word1 = input()
word2 = input()
diffs = len([idx for (idx, (c1, c2)) in enumerate(zip(word1, word2)) if c1 != c2])
minimum = (diffs + 1) // 2
switches = diffs - t if t <= diffs else 0
switch_polarity = 0
if t < minimum:
	print(-1)
else:
	new_word = []
	for (c1, c2) in zip(word1, word2):
		if c1 == c2:
			if t > diffs:
				new_word.append(get_other_char(c1, c2))
				t -= 1
			else:
				new_word.append(c1)
		elif switches:
			if switch_polarity == 0:
				new_word.append(c1)
				switch_polarity = 1
			else:
				new_word.append(c2)
				switch_polarity = 0
				switches -= 1
		else:
			new_word.append(get_other_char(c1, c2))
	print(''.join(new_word))


(n, m) = map(int, input().split())
a = input()
b = input()
c = []
d = [0] * n
c = [i for i in range(n) if a[i] == b[i]]
l = len(c)
for i in range(min(l, n - m)):
	d[c[i]] = a[c[i]]
if l < n - m:
	u = n - m - l
	if l + u + u > n:
		print(-1)
		return
	else:
		u = n - m - l
		for i in range(n):
			if d[i] == 0 and u > 0:
				d[i] = a[i]
				u -= 1
				if u == 0:
					break
		u = n - m - l
		for i in range(n):
			if d[i] == 0 and u > 0:
				d[i] = b[i]
				u -= 1
				if u == 0:
					break
for i in range(n):
	if d[i] == 0:
		for e in ['a', 'b', 'c']:
			if e != a[i] and e != b[i]:
				print(e, end='')
				break
	else:
		print(d[i], end='')


import sys
INF = 10 ** 20
MOD = 10 ** 9 + 7
I = lambda : list(map(int, input().split()))
from math import gcd
from math import ceil
from collections import defaultdict as dd, Counter
from bisect import bisect_left as bl, bisect_right as br
(n, k) = I()
s = input()
t = input()
ans = list(s)
cnt = 0
idx = []
for i in range(n):
	if s[i] != t[i]:
		idx.append(i)
	else:
		ans[i] = s[i]
a = 'abcde'
ok = len(idx)
req = 0
for i in range(ok + 1):
	if (ok - i) % 2:
		continue
	count = i + (ok - i) // 2
	if count + n - ok >= k and count <= k:
		req = max(0, k - count)
		for j in range(i):
			for ass in a:
				if ass != s[idx[j]] and ass != t[idx[j]]:
					ans[idx[j]] = ass
					break
		for j in range(i, ok):
			if j % 2:
				ans[idx[j]] = s[idx[j]]
			else:
				ans[idx[j]] = t[idx[j]]
		break
else:
	print(-1)
	exit()
for i in range(n):
	if not req:
		break
	if s[i] == t[i]:
		if s[i] == 'a':
			ans[i] = 'z'
		else:
			ans[i] = 'a'
		req -= 1
print(''.join(ans))


l = input().split()
n = int(l[0])
k = int(l[1])
s1 = input()
s2 = input()
count = 0
for i in range(n):
	if s1[i] != s2[i]:
		count += 1
if count > 2 * k:
	print(-1)
	quit()
pp = 0
for i in range(count + 1):
	if (count - i) % 2:
		continue
	done = i + (count - i + 1) // 2
	if k >= done and k - done <= n - count:
		samed = k - done
		sames = n - count - samed
		diffd = i
		diffs = count - i
		break
for i in range(n):
	if s1[i] == s2[i]:
		if samed:
			ok = ord(s1[i]) - ord('a') + 1
			ok %= 26
			print(chr(ord('a') + ok), end='')
			samed -= 1
		else:
			print(s1[i], end='')
			sames -= 1
	elif diffd:
		p = ['a', 'b', 'c']
		for j in p:
			if j != s1[i] and j != s2[i]:
				print(j, end='')
				break
		diffd -= 1
	elif diffs % 2:
		print(s1[i], end='')
		diffs -= 1
	else:
		print(s2[i], end='')
		diffs -= 1
print()


(n, t) = map(int, input().split())
str1 = list(input())
str2 = list(input())

def choice(a, b):
	for i in range(3):
		c = chr(i + ord('a'))
		if c != a and c != b:
			return c
common = [i for i in range(n) if str1[i] == str2[i]]
lc = len(common)
ld = n - lc
if ld // 2 + lc < n - t:
	print(-1)
	exit()
dist = n
changes_diff = 2 * min(n - t, ld // 2)
dist -= changes_diff // 2
ans = [-1] * n
flag = True
for (k, (a, b)) in enumerate(zip(str1, str2)):
	if changes_diff > 0:
		if a != b:
			ans[k] = a if flag else b
			flag = not flag
			changes_diff -= 1
	else:
		ans[k] = choice(a, b)
changes_comm = t - changes_diff // 2
for (k, (a, b)) in enumerate(zip(str1, str2)):
	if dist - t > 0:
		if a == b:
			ans[k] = a
			dist -= 1
	elif a == b:
		ans[k] = choice(a, b)
print(''.join(ans))


import sys
import math
a = list(input().split(' '))
n = int(a[0])
t = int(a[1])
a = input()
b = input()
x = 0
for i in range(n):
	if a[i] == b[i]:
		x += 1
if t < math.ceil((n - x) / 2.0):
	print(-1)
	sys.exit()
ans = ''
p = n - x - t
if p < 0:
	p = 0
q = t - p
r = t - n + x
if r < 0:
	r = 0
d = 0
e = 0
f = 0
for i in range(n):
	if a[i] == b[i]:
		if f < r:
			if a[i] == 'z':
				ans += 'a'
			else:
				ans += 'z'
			f += 1
		else:
			ans += a[i]
	elif e < 2 * p:
		if e % 2 == 0:
			ans += a[i]
		else:
			ans += b[i]
		e += 1
	else:
		if a[i] == 'a' or b[i] == 'a':
			if a[i] == 'b' or b[i] == 'b':
				ans += 'c'
			else:
				ans += 'b'
		else:
			ans += 'a'
		d += 1
print(ans)


(n, m) = map(int, input().split())
a = input()
b = input()
did = [0] * (n + 1)
for i in range(n):
	if a[i] == b[i]:
		did[i] = -1
k = m
for i in range(n):
	if k == 0:
		break
	if not did[i]:
		did[i] = 2
		k -= 1
if k:
	for i in range(n):
		if k == 0:
			break
		if did[i] == -1:
			did[i] = 3
			k -= 1
k = m
for i in range(n):
	if k == 0:
		break
	if not did[i]:
		did[i] = 1
		k -= 1
if k:
	for i in range(n):
		if k == 0:
			break
		if did[i] == 2:
			did[i] = 3
			k -= 1
f = 0
for i in range(n):
	if did[i] == 0:
		f = 1
		break
if f == 0:
	for i in range(n):
		if did[i] == -1:
			print(a[i], end='')
		elif did[i] == 1:
			print(b[i], end='')
		elif did[i] == 2:
			print(a[i], end='')
		else:
			for j in range(26):
				if chr(ord('a') + j) != a[i] and chr(ord('a') + j) != b[i]:
					print(chr(ord('a') + j), end='')
					break
else:
	print(-1)


(n, t) = map(int, input().split())
a = input()
b = input()
m = 0
for i in range(n):
	if a[i] != b[i]:
		m += 1
if n - t > n - m + (m >> 1):
	print(-1)
else:
	ls = []
	if m <= t:
		for i in range(n):
			if a[i] == b[i]:
				if m == t:
					ls.append(a[i])
				else:
					ls.append('a' if a[i] != 'a' else 'b')
					m += 1
			elif a[i] != 'a' and b[i] != 'a':
				ls.append('a')
			elif a[i] != 'b' and b[i] != 'b':
				ls.append('b')
			else:
				ls.append('c')
		ta = tb = 0
	else:
		ta = tb = m - t
		for i in range(n):
			if a[i] == b[i]:
				ls.append(a[i])
			elif ta > 0:
				ls.append(a[i])
				ta -= 1
			elif tb > 0:
				ls.append(b[i])
				tb -= 1
			elif a[i] != 'a' and b[i] != 'a':
				ls.append('a')
			elif a[i] != 'b' and b[i] != 'b':
				ls.append('b')
			else:
				ls.append('c')
	assert ta == tb == 0
	s = ''.join(ls)
	for i in range(n):
		if a[i] != s[i]:
			ta += 1
		if b[i] != s[i]:
			tb += 1
	assert ta == tb == t
	print(s)


(n, t) = map(int, input().split())
s1 = str(input())
s2 = str(input())
s3 = list()
for i in range(n):
	s3.append(ord('a'))
(c1, c2) = (0, 0)
su = 0
for i in range(n):
	su += s1[i] != s2[i]
changed = [0 for i in range(n)]
for i in range(n):
	if s1[i] != s2[i]:
		if su != 1 or (su == 1 and abs(c2 - c1) == 1):
			if c1 <= c2:
				c1 += 1
				s3[i] = ord(s1[i])
				changed[i] = 1
			else:
				c2 += 1
				s3[i] = ord(s2[i])
				changed[i] = 2
		else:
			if s1[i] != 'a' and s2[i] != 'a':
				s3[i] = ord('a')
			elif s1[i] != 'b' and s2[i] != 'b':
				s3[i] = ord('b')
			else:
				s3[i] = ord('c')
			c1 += 1
			c2 += 1
			changed[i] = 3
		su -= 1
	else:
		s3[i] = ord(s1[i])
for i in range(n):
	if t - c1 > 0 and changed[i] == 0:
		if s1[i] != 'a' and s2[i] != 'a':
			s3[i] = ord('a')
		elif s1[i] != 'b' and s2[i] != 'b':
			s3[i] = ord('b')
		else:
			s3[i] = ord('c')
		c1 += 1
		c2 += 1
for i in range(n):
	if t - min(c1, c2) > 0 and (changed[i] == 1 or changed[i] == 2):
		if s1[i] != 'a' and s2[i] != 'a':
			s3[i] = ord('a')
		elif s1[i] != 'b' and s2[i] != 'b':
			s3[i] = ord('b')
		else:
			s3[i] = ord('c')
		if changed[i] == 1:
			c2 += 1
		else:
			c1 += 1
if t != c1:
	print(-1)
else:
	for i in range(n):
		print(chr(s3[i]), end='')


from math import ceil
(n, t) = map(int, input().split())
s1 = input()
s2 = input()
s3 = ''

def func(s1, s2, i):
	return chr((max(ord(s1[i]), ord(s2[i])) - 97 + 1) % 26 + 97 + abs(ord(s1[i]) - ord(s2[i])) // 25)
mass = [0] * n
r = 0
for i in range(n):
	if s1[i] != s2[i]:
		mass[i] = 1
		r = r + 1
key0 = 0
cout1 = max(t - r, 0)
tmp = 2 * max(r - t, 0)
tmp0 = max(r - t, 0)
key1 = 0
if t < ceil(r / 2):
	print(-1)
else:
	for i in range(n):
		if s1[i] == s2[i]:
			if cout1 > 0:
				s3 = s3 + chr((ord(s1[i]) + 1 - 97) % 26 + 97)
				cout1 = cout1 - 1
			else:
				s3 = s3 + s1[i]
		if s1[i] != s2[i]:
			if tmp > 0:
				if tmp0 > 0:
					s3 = s3 + s1[i]
					tmp0 = tmp0 - 1
				else:
					s3 = s3 + s2[i]
				tmp = tmp - 1
			else:
				s3 = s3 + func(s1, s2, i)
print(s3)


(n, t) = map(int, input().split())
s1 = input()
s2 = input()
same = n - t
ans = ['' for i in range(n)]
for i in range(n):
	if same == 0:
		break
	if s1[i] == s2[i]:
		same -= 1
		ans[i] = s1[i]
same1 = same2 = same
for i in range(n):
	if ans[i] != '':
		continue
	if same1 != 0 and same1 >= same2:
		ans[i] = s1[i]
		same1 -= 1
	elif same2 != 0 and same2 >= same1:
		ans[i] = s2[i]
		same2 -= 1
	elif same1 == 0 and same2 == 0:
		if s1[i] != 'a' and s2[i] != 'a':
			ans[i] = 'a'
		elif s1[i] != 'b' and s2[i] != 'b':
			ans[i] = 'b'
		elif s1[i] != 'c' and s2[i] != 'c':
			ans[i] = 'c'
if same1 > 0 or same2 > 0:
	print(-1)
else:
	print(''.join(ans))


(n, t) = map(int, input().split())
aa = list(input().strip())
bb = list(input().strip())
cc = n * [' ']
want_same = n - t
mismatched = 0
for i in range(n):
	if aa[i] == bb[i]:
		if want_same == 0:
			for c in ['y', 'z']:
				if c != aa[i]:
					cc[i] = c
		else:
			cc[i] = aa[i]
			want_same -= 1
	else:
		mismatched += 1
		for c in ['x', 'y', 'z']:
			if c != aa[i] and c != bb[i]:
				cc[i] = c
				break
if 2 * want_same > mismatched:
	print(-1)
	import sys
	sys.exit()
if want_same != 0:
	want_same *= 2
	for i in range(n):
		if aa[i] != bb[i]:
			if want_same % 2 == 0:
				cc[i] = aa[i]
			else:
				cc[i] = bb[i]
			want_same -= 1
			if want_same == 0:
				break
print(''.join(cc))


import sys
(n, t) = map(int, input().split())
s1 = input()
s2 = input()
same = sum([1 for i in range(n) if s1[i] == s2[i]])

def other(c1, c2):
	ans = 'a'
	while ans == c1 or ans == c2:
		ans = chr(ord(ans) + 1)
	return ans
if same + 2 * t < n:
	print(-1)
	return
samehave = 0
sames1 = 0
sames2 = 0
ans = ['v'] * n
for i in range(n):
	if s1[i] == s2[i]:
		if sames1 < n - t and sames2 < n - t:
			ans[i] = s1[i]
			sames1 += 1
			sames2 += 1
		else:
			ans[i] = other(s1[i], s2[i])
for i in range(n):
	if s1[i] != s2[i]:
		if sames1 < n - t:
			sames1 += 1
			ans[i] = s1[i]
		elif sames2 < n - t:
			sames2 += 1
			ans[i] = s2[i]
		else:
			ans[i] = other(s1[i], s2[i])
print(*ans, sep='')


(n, t) = map(int, input().split())
s1 = input().strip()
s2 = input().strip()
a2z = 'abcdefghijklmnopqrstuvwxyz'

def solve(n, t, s1, s2):
	same = 0
	for (c1, c2) in zip(s1, s2):
		if c1 == c2:
			same += 1
	dif = n - same
	c_upper = min(dif // 2, t, n - t)
	c_lower = max(0, n - t - same)
	if c_lower > c_upper:
		return -1
	c = c_lower
	c00 = n - t - c
	c11 = t - c
	c01 = c
	c10 = c
	s3 = []
	for (c1, c2) in zip(s1, s2):
		if c1 == c2:
			if c00:
				c00 -= 1
				s3.append(c1)
			else:
				c11 -= 1
				s3.append(difchar(c1, c2))
		elif c01:
			c01 -= 1
			s3.append(c2)
		elif c10:
			c10 -= 1
			s3.append(c1)
		else:
			c11 -= 1
			s3.append(difchar(c1, c2))
	return ''.join(s3)

def difchar(c1, c2):
	for c3 in a2z:
		if c3 != c1 and c3 != c2:
			return c3
print(solve(n, t, s1, s2))


def main():

	def getD(c1, c2):
		for i in [chr(i) for i in range(ord('a'), ord('z') + 1)]:
			if i != c1 and i != c2:
				return i
	(n, t) = map(int, input().split())
	s1 = input()
	s2 = input()
	s3 = ['-'] * n
	same = 0
	for (i, v) in enumerate(s1):
		if v == s2[i]:
			same += 1
	if n - t <= same:
		cnt = n - t
		for (i, v) in enumerate(s1):
			if cnt <= 0:
				break
			if v == s2[i]:
				s3[i] = v
				cnt -= 1
		for (i, v) in enumerate(s3):
			if v == '-':
				s3[i] = getD(s1[i], s2[i])
		print(''.join(s3))
	else:
		cnt = n - t
		for (i, v) in enumerate(s1):
			if v == s2[i]:
				s3[i] = v
				cnt -= 1
		cnt1 = cnt
		for (i, v) in enumerate(s3):
			if cnt1 <= 0:
				break
			if v == '-':
				s3[i] = s1[i]
				cnt1 -= 1
		if cnt1 > 0:
			print(-1)
			return
		cnt2 = cnt
		for (i, v) in enumerate(s3):
			if cnt2 <= 0:
				break
			if v == '-':
				s3[i] = s2[i]
				cnt2 -= 1
		if cnt2:
			print(-1)
			return
		for (i, v) in enumerate(s3):
			if v == '-':
				s3[i] = getD(s1[i], s2[i])
		print(''.join(s3))
	return
main()


def other(c1, c2):
	if c1 != 'z' and c2 != 'z':
		return 'z'
	elif c1 != 'y' and c2 != 'y':
		return 'y'
	else:
		return 'x'
(n, t) = map(int, input().split())
s1 = input()
s2 = input()
f = sum((1 if c1 != c2 else 0 for (c1, c2) in zip(s1, s2)))
if f > 2 * t:
	print(-1)
elif f >= t:
	result = []
	diff = 0
	for (c1, c2) in zip(s1, s2):
		if c1 == c2:
			result.append(c1)
		else:
			if diff < f - t:
				result.append(c2)
			elif diff < t:
				result.append(other(c1, c2))
			else:
				result.append(c1)
			diff += 1
	print(''.join(result))
else:
	result = []
	usedeq = 0
	for (c1, c2) in zip(s1, s2):
		if c1 == c2:
			if usedeq < t - f:
				result.append(other(c1, c1))
				usedeq += 1
			else:
				result.append(c1)
		else:
			result.append(other(c1, c2))
	print(''.join(result))


def main():
	import sys
	(n, t, s1, s2) = sys.stdin.read().split()
	(n, t) = (int(n), int(t))
	result = [-1] * n
	rest = n - t
	for i in range(n):
		if rest == 0:
			break
		if s1[i] == s2[i]:
			result[i] = s1[i]
			rest -= 1
	k = rest
	for i in range(n):
		if k == 0:
			break
		if result[i] == -1:
			result[i] = s1[i]
			k -= 1
	k = rest
	for i in range(n):
		if k == 0:
			break
		if result[i] == -1:
			result[i] = s2[i]
			k -= 1
	if k > 0:
		print(-1)
		return
	for i in range(n):
		if result[i] == -1:
			for j in range(ord('a'), ord('a') + 4):
				if chr(j) != s1[i] and chr(j) != s2[i]:
					result[i] = chr(j)
					break
	sys.stdout.write(''.join(result))
main()


(n, t) = map(int, input().split())
s1 = list(input())
s2 = list(input())
lowercase = set([chr(i) for i in range(ord('a'), ord('z') + 1)])
ans = [False for i in range(n)]
count = 0
for i in range(n):
	if s1[i] != s2[i]:
		count += 1
	else:
		ans[i] = s1[i]
if count > t and count < (count - t) * 2:
	print(-1)
else:
	for i in range(n):
		if count > t and (not ans[i]):
			ans[i] = s1[i]
			for j in range(i, n):
				if not ans[j]:
					ans[j] = s2[j]
					break
			count -= 1
		elif count < t and ans[i] is not False:
			ans[i] = (lowercase - set(s1[i]) - set(s2[i])).pop()
			count += 1
		elif not ans[i]:
			ans[i] = (lowercase - set(s1[i]) - set(s2[i])).pop()
	print(''.join(ans))


(n, t) = [int(x) for x in input().split()]
a = input()
b = input()
c = [0] * n
s = set()
otl = []
lotl = 0
for i in range(n):
	if a[i] != b[i]:
		otl.append(i)
		lotl += 1
	else:
		c[i] = a[i]
		s.add(i)
if lotl > 2 * t:
	print(-1)
else:
	ind1 = max(lotl - t, 0)
	ind2 = max(lotl - t, 0)
	for i in range(lotl):
		if ind1 != 0:
			c[otl[i]] = a[otl[i]]
			ind1 -= 1
		elif ind2 != 0:
			c[otl[i]] = b[otl[i]]
			ind2 -= 1
		elif chr(ord(a[otl[i]]) + 1) != b[otl[i]] and chr(ord(a[otl[i]]) + 1) <= 'z':
			c[otl[i]] = chr(ord(a[otl[i]]) + 1)
		elif chr(ord(a[otl[i]]) - 1) != b[otl[i]] and chr(ord(a[otl[i]]) - 1) >= 'a':
			c[otl[i]] = chr(ord(a[otl[i]]) - 1)
		else:
			c[otl[i]] = 'l'
		t -= 1
	if t > 0:
		for i in s:
			if chr(ord(a[i]) + 1) <= 'z':
				c[i] = chr(ord(a[i]) + 1)
			elif chr(ord(a[i]) - 1) >= 'a':
				c[i] = chr(ord(a[i]) - 1)
			t -= 1
			if t == 0:
				break
	print(''.join(c))


(n, t) = map(int, input().split())
s1 = input()
s2 = input()
ans = ['' for i in range(n)]
k = n - t
for i in range(n):
	if k == 0:
		break
	if s1[i] == s2[i]:
		ans[i] = s1[i]
		k -= 1
k1 = k
k2 = k
for i in range(n):
	if ans[i] != '':
		continue
	if 0 != k1 >= k2:
		ans[i] = s1[i]
		k1 -= 1
	elif 0 != k2 >= k1:
		ans[i] = s2[i]
		k2 -= 1
	elif k1 == k2 == 0:
		if s1[i] != 'a' != s2[i]:
			ans[i] = 'a'
		elif s1[i] != 'b' != s2[i]:
			ans[i] = 'b'
		else:
			ans[i] = 'c'
if k1 > 0 or k2 > 0:
	print(-1)
else:
	print(*ans, sep='')


from sys import exit
(n, m) = map(int, input().split())
a = input()
b = input()
c = []
d = [0] * n
c = [i for i in range(n) if a[i] == b[i]]
l = len(c)
for i in range(min(l, n - m)):
	d[c[i]] = a[c[i]]
if l < n - m:
	u = n - m - l
	if l + u + u > n:
		print(-1)
		exit(0)
	else:
		u = n - m - l
		for i in range(n):
			if d[i] == 0 and u > 0:
				d[i] = a[i]
				u -= 1
				if u == 0:
					break
		u = n - m - l
		for i in range(n):
			if d[i] == 0 and u > 0:
				d[i] = b[i]
				u -= 1
				if u == 0:
					break
for i in range(n):
	if d[i] == 0:
		for e in ['a', 'b', 'c']:
			if e != a[i] and e != b[i]:
				print(e, end='')
				break
	else:
		print(d[i], end='')


(n, t) = map(int, input().split())
s1 = input()
s2 = input()
co = 0
for i in range(n):
	if s1[i] == s2[i]:
		co += 1
t = n - t
from_co = min(co, t)
(from_s1, from_s2) = (max(t - from_co, 0), max(t - from_co, 0))
if from_co + from_s1 + from_s2 > n:
	print(-1)
else:
	new_s = []
	for i in range(n):
		if from_co > 0 and s1[i] == s2[i]:
			new_s.append(s1[i])
			from_co -= 1
		elif from_s1 > 0 and s1[i] != s2[i]:
			new_s.append(s1[i])
			from_s1 -= 1
		elif from_s2 > 0 and s1[i] != s2[i]:
			new_s.append(s2[i])
			from_s2 -= 1
		else:
			f = ['a', 'b', 'c']
			if s1[i] in f:
				f.remove(s1[i])
			if s2[i] in f:
				f.remove(s2[i])
			new_s.append(f[0])
	print(''.join(new_s))


(n, t) = map(int, input().split())
s1 = str(input())
s2 = str(input())
ans = []
mode = 1
t = n - t
last = -1
for i in range(n):
	if t == 0:
		if s1[i] != 'a' and s2[i] != 'a':
			ans.append('a')
		elif s1[i] != 'b' and s2[i] != 'b':
			ans.append('b')
		else:
			ans.append('c')
	elif s1[i] == s2[i]:
		t -= 1
		ans.append(s1[i])
	elif mode == 1:
		ans.append(s1[i])
		mode = 0
		last = i
	else:
		ans.append(s2[i])
		mode = 1
		t -= 1
		last = -1
if last >= 0:
	if s1[last] != 'a' and s2[last] != 'a':
		ans[last] = 'a'
	elif s1[last] != 'b' and s2[last] != 'b':
		ans[last] = 'b'
	else:
		ans[last] = 'c'
if t == 0:
	for i in ans:
		print(i, end='')
else:
	print(-1)


def generate(first_char, second_char):
	if first_char != 'a' and second_char != 'a':
		return 'a'
	elif first_char != 'b' and second_char != 'b':
		return 'b'
	else:
		return 'c'

def right_answer(first, second, length):
	res = 0
	for i in range(length):
		if first[i] != second[i]:
			res += 1
	return res
(n, t) = [int(i) for i in input().split()]
(first, second, third, equal, dif) = (list(input()), list(input()), ['a'] * n, [False] * n, 0)
for i in range(n):
	if first[i] != second[i]:
		dif += 1
	else:
		equal[i] = True
if t == dif:
	for i in range(n):
		third[i] = first[i] if equal[i] else generate(first[i], second[i])
elif t > dif:
	counter = 0
	for i in range(n):
		if equal[i]:
			if counter < t - dif:
				third[i] = generate(first[i], second[i])
				counter += 1
			else:
				third[i] = first[i]
		else:
			third[i] = generate(first[i], second[i])
else:
	(counter1, counter2) = (0, 0)
	for i in range(n):
		if equal[i]:
			third[i] = first[i]
		elif counter1 < dif - t:
			third[i] = first[i]
			counter1 += 1
		elif counter2 < dif - t:
			third[i] = second[i]
			counter2 += 1
		else:
			third[i] = generate(first[i], second[i])
if right_answer(first, third, n) == t and right_answer(second, third, n) == t:
	print(''.join(third))
else:
	print('-1')


def other(ch1, ch2):
	for char in 'abc':
		if ch1 != char and ch2 != char:
			return char
(n, t) = list(map(int, input().split()))
s1 = input()
s2 = input()
diff = 0
for (ch1, ch2) in zip(s1, s2):
	if ch1 != ch2:
		diff += 1
same = n - diff
if n < t or 2 * t < diff:
	print(-1)
else:
	changediff = min(t, diff)
	changesame = max(0, t - diff)
	res = [None] * n
	(samefirst, samesecond) = (diff - t, diff - t)
	i = -1
	for (ch1, ch2) in zip(s1, s2):
		i += 1
		if ch1 == ch2:
			if changesame:
				res[i] = other(ch1, ch2)
				changesame -= 1
			else:
				res[i] = ch1
		elif changediff == diff:
			res[i] = other(ch1, ch2)
		elif samefirst:
			res[i] = ch1
			samefirst -= 1
		elif samesecond:
			res[i] = ch2
			samesecond -= 1
		else:
			res[i] = other(ch1, ch2)
	print(''.join(map(str, res)))


import string
(n, t) = map(int, input().split())
s1 = input()
s2 = input()

def otherchr(*args):
	for i in string.ascii_lowercase:
		if i not in args:
			return i
diff = []
same = []
str = [ch for ch in s1]
for i in range(n):
	if s1[i] != s2[i]:
		diff.append(i)
	else:
		same.append(i)
temp = len(diff)
if temp > 2 * t:
	print(-1)
else:
	if t > temp:
		count = t - temp
		for i in diff:
			str[i] = otherchr(s1[i], s2[i])
		for i in same[:count]:
			str[i] = otherchr(s1[i], s2[i])
	elif t == temp:
		for i in diff:
			str[i] = otherchr(s1[i], s2[i])
	else:
		count = temp - t
		for i in range(count, 2 * count):
			str[diff[i]] = s2[diff[i]]
		for i in range(2 * count, temp):
			str[diff[i]] = otherchr(s1[diff[i]], s2[diff[i]])
	print(''.join(str))


(n, t) = map(int, input().split())
s1 = input()
s2 = input()
rest = n - t
output = [-1] * n
for i in range(n):
	if rest == 0:
		break
	if s1[i] == s2[i]:
		output[i] = s1[i]
		rest -= 1
k = rest
for i in range(n):
	if k == 0:
		break
	if output[i] == -1:
		output[i] = s1[i]
		k -= 1
k = rest
for i in range(n):
	if k == 0:
		break
	if output[i] == -1:
		output[i] = s2[i]
		k -= 1
if k > 0:
	print(-1)
	exit()
for i in range(n):
	if output[i] == -1:
		for j in range(ord('a'), ord('a') + 4):
			if chr(j) != s1[i] and chr(j) != s2[i]:
				output[i] = chr(j)
				break
print(''.join(output))


def diff(c1, c2):
	alph = 'abcdefghijklmnopqrstuvwxyz'
	for c in alph:
		if c != c1 and c != c2:
			return c
(n, t) = map(int, input().split())
s1 = input()
s2 = input()
s3 = []
same1 = 0
same2 = 0
last1 = -1
last2 = -1
i = 0
first = True
while (same1 < n - t or same2 < n - t) and i < n:
	if s1[i] == s2[i]:
		if same1 + 1 > n - t:
			s3[last1] = diff(s1[last1], s2[last1])
			same1 -= 1
		elif same2 + 1 > n - t:
			s3[last2] = diff(s1[last2], s2[last2])
			same2 -= 1
		s3.append(s1[i])
		same1 += 1
		same2 += 1
	elif s1[i] == s2[i]:
		s3 += diff(s1[i], s2[i])
	else:
		if first:
			s3.append(s1[i])
			same1 += 1
			last1 = i
		else:
			s3.append(s2[i])
			same2 += 1
			last2 = i
		first = not first
	i += 1
if same1 != same2 or same1 == same2 != n - t:
	print(-1)
else:
	remaining = n - len(s3)
	for i in range(len(s3), n):
		s3 += diff(s1[i], s2[i])
	print(''.join(s3))


import os
import sys
from io import BytesIO, IOBase
BUFSIZE = 8192

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')
(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
input = lambda : sys.stdin.readline().rstrip('\r\n')
(n, t) = map(int, input().split())
s1 = input()
s2 = input()
l = []
c = 0
for i in range(n):
	if s1[i] != s2[i]:
		c += 1
if c > 2 * t:
	print(-1)
elif c <= t:
	for i in range(n):
		if s1[i] != s2[i]:
			if abs(ord(s1[i]) - ord(s2[i])) > 1:
				l.append(chr(min(ord(s2[i]) + 1, ord(s1[i]) + 1)))
			elif max(ord(s1[i]) + 1, ord(s2[i]) + 1) > 122:
				l.append(chr(max(ord(s1[i]), ord(s2[i])) - 2))
			else:
				l.append(chr(max(ord(s1[i]) + 1, ord(s2[i]) + 1)))
			t -= 1
		else:
			l.append(s1[i])
	if t > 0:
		i = 0
		while t:
			if s1[i] == s2[i]:
				if s1[i] != 'z':
					l[i] = 'z'
				else:
					l[i] = 'y'
				t -= 1
			i += 1
			if i == n:
				break
	print(''.join(l))
else:
	i = 0
	a = 0
	x = 2 * t - c
	c = c - x
	l = [''] * n
	while x > 0:
		if s1[i] != s2[i]:
			if abs(ord(s1[i]) - ord(s2[i])) > 1:
				l[i] = chr(min(ord(s2[i]) + 1, ord(s1[i]) + 1))
			elif max(ord(s1[i]) + 1, ord(s2[i]) + 1) > 122:
				l[i] = chr(max(ord(s1[i]), ord(s2[i])) - 2)
			else:
				l[i] = chr(max(ord(s1[i]) + 1, ord(s2[i]) + 1))
			x -= 1
		else:
			l[i] = s1[i]
		i += 1
		if i == n:
			break
	while c:
		if s1[i] != s2[i]:
			if a % 2:
				l[i] = s1[i]
				c -= 1
				a = a ^ 1
			else:
				l[i] = s2[i]
				c -= 1
				a = a ^ 1
		else:
			l[i] = s1[i]
		i += 1
		if i == n:
			break
	if i != n:
		while i < n:
			if s1[i] == s2[i]:
				l[i] = s1[i]
			i += 1
	print(''.join(l))


from math import ceil, floor

def round1(x):
	return ceil(x) if x - int(x) >= 0.5 else floor(x)

def get_char(x, y):
	for i in range(ord('a'), ord('z') + 1):
		if chr(i) not in [x, y]:
			return chr(i)
(n, t) = map(int, input().split())
(s1, s2, mi) = (input(), input(), 0)
for i in range(n):
	if s1[i] != s2[i]:
		mi += 1
mi1 = mi / 2
if t < round1(mi1):
	print(-1)
else:
	(ans, ext, c) = (['' for i in range(n)], max(t - mi, 0), 0)
	mi = min(t, mi)
	for i in range(n):
		if s1[i] != s2[i]:
			if mi != mi1:
				mi -= 1
				mi1 -= 0.5
				ans[i] = get_char(s1[i], s2[i])
			else:
				mi -= 1
				mi1 -= 1
				ans[i] = s1[i] if c % 2 else s2[i]
				c += 1
		elif ext:
			ans[i] = get_char(s1[i], s2[i])
			ext -= 1
		else:
			ans[i] = s1[i]
	print(''.join(ans))


from sys import stdin, stdout
input = stdin.readline
(n, t) = list(map(int, input().split()))
s1 = input()[:-1]
s2 = list(input()[:-1])
if t > n:
	stdout.write('-1')
	return
d = [False] * n
m = 0
for i in range(n):
	if s2[i] == s1[i]:
		d[i] = True
		m += 1
d1 = d2 = n - t
ans = [''] * n
for i in range(n):
	if d[i] and d2 != 0 and (d1 != 0):
		d2 -= 1
		d1 -= 1
		ans[i] = s1[i]
for i in range(n):
	if not d[i]:
		if d1 != 0:
			ans[i] = s1[i]
			d1 -= 1
			continue
		if d2 != 0:
			ans[i] = s2[i]
			d2 -= 1
			continue
for j in range(n):
	if ans[j] == '':
		for i in range(26):
			al = chr(ord('a') + i)
			if s1[j] != al and s2[j] != al:
				ans[j] = al
				break
		if ans[j] == '':
			stdout.write('-1')
if d1 == 0 and d2 == 0:
	stdout.write(''.join(ans))
else:
	stdout.write('-1')


from sys import exit

def cdiff(c1, c2):
	ch = 'a'
	while ch in (c1, c2):
		ch = chr(ord(ch) + 1)
	return ch
(n, t) = map(int, input().split())
a = input()
b = input()
ra = 0
rb = 0
c = [-1] * n
for i in range(n):
	c[i] = (a[i], b[i])[(ra + rb) % 2]
	ra += c[i] != a[i]
	rb += c[i] != b[i]
if rb < ra:
	(ra, rb) = (rb, ra)
	(a, b) = (b, a)
if ra < rb:
	for i in range(n):
		if c[i] != b[i] and c[i] == a[i]:
			c[i] = cdiff(a[i], b[i])
			ra += 1
			break
	if ra < rb:
		print(-1)
		exit(0)
if t < ra:
	print(-1)
	exit(0)
i = 0
lst = -1
while ra < t and i < n:
	if a[i] == b[i]:
		c[i] = cdiff(a[i], b[i])
		ra += 1
		rb += 1
	elif c[i] not in (a[i], b[i]):
		pass
	elif lst == -1:
		lst = i
	else:
		c[lst] = cdiff(a[lst], b[lst])
		c[i] = cdiff(a[i], b[i])
		lst = -1
		ra += 1
		rb += 1
	i += 1
if ra != t:
	print(-1)
	exit(0)
print(*c, sep='')


(n, k) = map(int, input().split())
a = input()
b = input()
c = []
ans = 0
for i in range(n):
	if a[i] == b[i]:
		ans += 1
si = n - k
d = ['a', 'b', 'c']
if ans >= si:
	for i in range(n):
		if a[i] == b[i] and si > 0:
			c.append(a[i])
			si -= 1
		else:
			ee = [a[i], b[i]]
			if 'a' not in ee:
				c.append('a')
			elif 'c' not in ee:
				c.append('c')
			else:
				c.append('b')
	print(''.join(c))
else:
	re1 = si - ans
	re2 = si - ans
	for i in range(n):
		if a[i] == b[i]:
			c.append(a[i])
		elif re1 > 0:
			c.append(a[i])
			re1 -= 1
		elif re2 > 0:
			c.append(b[i])
			re2 -= 1
		else:
			ee = [a[i], b[i]]
			if 'a' not in ee:
				c.append('a')
			elif 'c' not in ee:
				c.append('c')
			else:
				c.append('b')
	if re1 + re2 == 0:
		print(''.join(c))
	else:
		print(-1)


__author__ = 'ploskov'

def main():
	(n, t) = map(int, input().split())
	word1 = input()
	word2 = input()
	different = 0
	result = []
	for i in range(n):
		if word1[i] != word2[i]:
			different += 1
			result.append('_')
		else:
			result.append(word1[i])
	alphabet = [chr(c) for c in range(ord('a'), ord('z') + 1)]
	if t < different // 2 + different % 2:
		print(-1)
	elif t <= different:
		count1 = different - t
		count2 = different - t
		for index in range(len(result)):
			if result[index] == '_':
				if count1:
					result[index] = word1[index]
					count1 -= 1
					continue
				if count2:
					result[index] = word2[index]
					count2 -= 1
					continue
				for char in alphabet:
					if char != word1[index] and char != word2[index]:
						result[index] = char
						break
		print(''.join(result))
	else:
		t -= different
		for index in range(len(result)):
			if result[index] == '_':
				for char in alphabet:
					if char != word1[index] and char != word2[index]:
						result[index] = char
						break
			elif t:
				for char in alphabet:
					if char != word1[index] and char != word2[index]:
						result[index] = char
						break
				t -= 1
		print(''.join(result))
main()


(N, T) = map(int, input().split())
S1 = input().rstrip()
S2 = input().rstrip()
diff = []
for i in range(N):
	if S1[i] != S2[i]:
		diff.append(i)
import sys
if T * 2 < len(diff):
	print(-1)
	sys.exit(0)
ans = [None for i in range(N)]
while len(diff) > T and T:
	for i in range(2):
		idx = diff[-1]
		diff.pop()
		if i == 1:
			ans[idx] = S1[idx]
		else:
			ans[idx] = S2[idx]
	T -= 1
while T and diff:
	idx = diff[-1]
	diff.pop()
	for x in ('a', 'b', 'c'):
		if x == S1[idx] or x == S2[idx]:
			continue
		ans[idx] = x
		break
	T -= 1
assert not diff
for i in range(N):
	if not ans[i]:
		if T:
			T -= 1
			ans[i] = 'a' if S1[i] != 'a' else 'b'
		else:
			ans[i] = S1[i]
print(''.join(ans))


(n, k) = [int(i) for i in input().split(' ')]
s = input()
t = input()
same = 0
for i in range(n):
	if s[i] == t[i]:
		same += 1
diff = n - same
min_diff = n - (same + diff // 2)
if min_diff > k:
	print(-1)
else:
	ans = {}
	simm = 0
	req = n - k
	i = 0
	f = True
	while simm < req:
		if s[i] == t[i]:
			ans[i] = s[i]
			simm += 1
		elif f:
			aha = i
			f = not f
		else:
			ans[aha] = s[aha]
			ans[i] = t[i]
			f = not f
			simm += 1
		i += 1
	if f == False:
		if 'a' != s[aha] and 'a' != t[aha]:
			ans[aha] = 'a'
		elif 'b' != s[aha] and 'b' != t[aha]:
			ans[aha] = 'b'
		elif 'c' != s[aha] and 'c' != t[aha]:
			ans[aha] = 'c'
		else:
			ans[aha] = 'd'
	while i < n:
		if 'a' != s[i] and 'a' != t[i]:
			ans[i] = 'a'
		elif 'b' != s[i] and 'b' != t[i]:
			ans[i] = 'b'
		elif 'c' != s[i] and 'c' != t[i]:
			ans[i] = 'c'
		else:
			ans[i] = 'd'
		i += 1
	for i in range(n):
		print(ans[i], end='')
	print()


(n, t) = map(int, input().split())
s1 = input()
s2 = input()
p1 = n - t
p2 = n - t
s = [' ' for i in range(n)]
c = 'abcdefghtyux'
for i in range(n):
	if s1[i] == s2[i] and p1 > 0 and (p2 > 0):
		s[i] = s1[i]
		p1 -= 1
		p2 -= 1
for i in range(n):
	if p1 > 0 and s[i] == ' ':
		p1 -= 1
		s[i] = s1[i]
	elif p2 > 0 and s[i] == ' ':
		p2 -= 1
		s[i] = s2[i]
if p1 == 0 and p2 == 0:
	for i in range(n):
		if s[i] == ' ':
			for x in range(len(c)):
				if c[x] != s1[i] and c[x] != s2[i]:
					s[i] = c[x]
					break
	print(''.join((str(p) for p in s)))
else:
	print('-1')


alp = ['z', 'y', 'x', 'w', 'v', 'u', 't', 's', 'r', 'q', 'p', 'o', 'n', 'm', 'l', 'k', 'j', 'i', 'h', 'g', 'f', 'e', 'd', 'c', 'b', 'a']
(a, b) = input().split()
a = int(a)
b = int(b)
s1 = input()
s2 = input()
if b == 0 and s1 != s2:
	print(-1)
else:
	c = 0
	d = []
	for i in range(a):
		if s1[i] == s2[i]:
			c = c + 1
	x = a - b
	res = ''
	f = 0
	if c >= x:
		for i in range(a):
			if s1[i] == s2[i] and f != x:
				res += s1[i]
				f += 1
			else:
				for j in alp:
					if j != s1[i] and j != s2[i]:
						res += j
						break
	elif a - c < 2 * (x - c):
		print(-1)
	else:
		t = x - c
		q = 0
		for i in range(a):
			if s1[i] == s2[i] and f != x:
				res += s1[i]
			elif q < t:
				res += s1[i]
				q += 1
			elif q < 2 * t:
				res += s2[i]
				q += 1
			else:
				for j in alp:
					if j != s1[i] and j != s2[i]:
						res += j
						break
	print(res)


import sys
f = sys.stdin
(n, t) = map(int, f.readline().strip().split())
s1 = f.readline().strip()
s2 = f.readline().strip()
eq = 0
for i in range(n):
	if s1[i] == s2[i]:
		eq += 1
neq = n - eq
sq = []
if eq >= n - t:
	change_n = eq - (n - t)
	for i in range(n):
		if s1[i] == s2[i]:
			if change_n > 0:
				if s1[i] == 'a':
					sq.append('b')
				else:
					sq.append('a')
				change_n -= 1
			else:
				sq.append(s1[i])
		elif s1[i] == 'a' or s2[i] == 'a':
			if s1[i] == 'b' or s2[i] == 'b':
				sq.append('c')
			else:
				sq.append('b')
		else:
			sq.append('a')
elif neq // (n - t - eq) >= 2:
	change_n = n - t - eq
	step = 1
	for i in range(n):
		if s1[i] == s2[i]:
			sq.append(s1[i])
		elif change_n > 0:
			if step == 1:
				sq.append(s1[i])
				step = 2
			else:
				sq.append(s2[i])
				step = 1
				change_n -= 1
		elif s1[i] == 'a' or s2[i] == 'a':
			if s1[i] == 'b' or s2[i] == 'b':
				sq.append('c')
			else:
				sq.append('b')
		else:
			sq.append('a')
else:
	sq = ['-1']
print(''.join(sq))


from sys import stdin, stdout
import string
input = stdin.readline
(n, t) = list(map(int, input().split()))
a = input().strip()
b = input().strip()

def not_a_not_b(a, b):
	letters = string.ascii_lowercase
	for el in letters:
		if el != a and el != b:
			return el
diver = []
equal = []
ans = list(a)
for (index, el) in enumerate(a):
	if el == b[index]:
		equal.append(index)
	else:
		diver.append(index)
if len(diver) > t * 2:
	stdout.write('-1')
else:
	if t >= len(diver):
		for ind in diver:
			ans[ind] = not_a_not_b(a[ind], b[ind])
		t -= len(diver)
		for ind in range(t):
			ans[equal[ind]] = not_a_not_b(a[equal[ind]], b[equal[ind]])
	else:
		s = len(diver)
		s -= t
		for ind in diver[:s]:
			ans[ind] = a[ind]
		for ind in diver[s:s + s]:
			ans[ind] = b[ind]
		for ind in diver[s + s:]:
			ans[ind] = not_a_not_b(a[ind], b[ind])
	stdout.write('{}\n'.format(''.join(ans)))


(n, t) = map(int, input().split())
(a, b) = (input(), input())
k = len([1 for (i, j) in zip(a, b) if i != j])
if t < (k + 1) // 2:
	print(-1)
else:
	p = -1
	ans = ['0'] * n
	for i in range(n):
		if a[i] != b[i] and k > t:
			if p == -1:
				p = i
			else:
				ans[p] = a[p]
				ans[i] = b[i]
				p = -1
				k -= 2
				t -= 1
	for i in range(n):
		if a[i] != b[i] and ans[i] == '0':
			for v in 'abc':
				if v != a[i] and v != b[i]:
					ans[i] = v
					break
			t -= 1
	for i in range(n):
		if a[i] == b[i] and t:
			ans[i] = 'a' if 'a' != a[i] else 'b'
			t -= 1
		elif a[i] == b[i]:
			ans[i] = a[i]
	print(''.join(ans))


def f(s1, s2):
	return sum((0 if ch1 == ch2 else 1 for (ch1, ch2) in zip(s1, s2)))

def choose_different(ch1, ch2):
	if ch1 != 'a' and ch2 != 'a':
		return 'a'
	if ch1 != 'b' and ch2 != 'b':
		return 'b'
	return 'c'

def calc_s3(s1, s2, in_match, out_match):
	l3 = []
	in_match_taken = 0
	out_match_taken_1 = 0
	out_match_taken_2 = 0
	for (ch1, ch2) in zip(s1, s2):
		if ch1 == ch2:
			if in_match_taken < in_match:
				ch3 = ch1
				in_match_taken += 1
			else:
				ch3 = choose_different(ch1, ch2)
		elif out_match_taken_1 < out_match:
			ch3 = ch1
			out_match_taken_1 += 1
		elif out_match_taken_2 < out_match:
			ch3 = ch2
			out_match_taken_2 += 1
		else:
			ch3 = choose_different(ch1, ch2)
		l3.append(ch3)
	return ''.join(l3)

def main():
	(n, t) = [int(t) for t in input().split()]
	s1 = input()
	s2 = input()
	dif_12 = f(s1, s2)
	match_12 = n - dif_12
	highest_match = match_12 + dif_12 // 2
	match_require = n - t
	if match_require > highest_match:
		print(-1)
		return
	if match_12 >= match_require:
		in_match = match_require
		out_match = 0
	else:
		in_match = match_12
		out_match = match_require - match_12
	s3 = calc_s3(s1, s2, in_match, out_match)
	print(s3)
main()


import string
(n, k) = map(int, input().split())
s1 = list(input())
s2 = list(input())

def getChar(a, b):
	for c in string.ascii_lowercase:
		if c != a and c != b:
			return c
diffs = 0
for idx in range(n):
	if s1[idx] != s2[idx]:
		diffs += 1
s3 = s1.copy()
if diffs == k:
	for idx in range(n):
		if s1[idx] != s2[idx]:
			s3[idx] = getChar(s1[idx], s2[idx])
	print(''.join(s3))
elif diffs < k:
	for idx in range(n):
		if s1[idx] != s2[idx]:
			s3[idx] = getChar(s1[idx], s2[idx])
	for idx in range(n):
		if s1[idx] == s2[idx]:
			diffs += 1
			s3[idx] = getChar(s1[idx], s2[idx])
			if diffs == k:
				break
	if diffs == k:
		print(''.join(s3))
	else:
		print(-1)
elif diffs > k:
	if 2 * k >= diffs:
		for idx in range(n):
			if s1[idx] != s2[idx]:
				s3[idx] = getChar(s1[idx], s2[idx])
		first = True
		for idx in range(n):
			if s1[idx] != s2[idx]:
				if first:
					s3[idx] = s1[idx]
				else:
					s3[idx] = s2[idx]
					diffs -= 1
				first = not first
				if diffs == k:
					break
		print(''.join(s3))
	else:
		print(-1)


String = ['x', 'y', 'z']
(n, t) = map(int, input().split())
s1 = input()
s2 = input()
k = n - t
count = 0
ans = ''
for i in range(n):
	if s1[i] == s2[i]:
		count += 1
number = n - count
if count >= k:
	for i in range(n):
		if s1[i] == s2[i] and k > 0:
			ans += s1[i]
			k -= 1
		else:
			for s in String:
				if s != s1[i] and s != s2[i]:
					ans += s
					break
	print(ans)
elif number > 2 * t:
	print('-1')
elif number <= 2 * t:
	ballance1 = number - t
	ballance2 = number - t
	for i in range(n):
		if s1[i] == s2[i]:
			ans += s1[i]
		elif ballance1:
			ans += s1[i]
			ballance1 -= 1
		elif ballance2:
			ans += s2[i]
			ballance2 -= 1
		else:
			for s in String:
				if s != s1[i] and s != s2[i]:
					ans += s
					break
	print(ans)


(n, t) = map(int, input().split())
s1 = str(input())
s2 = str(input())
(s1cnt, s2cnt) = (n - t, n - t)
ans = [None] * n
for i in range(n):
	(ch1, ch2) = (s1[i], s2[i])
	if ch1 == ch2 and s1cnt and s2cnt:
		ans[i] = ch1
		s1cnt -= 1
		s2cnt -= 1
for i in range(n):
	(ch1, ch2) = (s1[i], s2[i])
	if s1cnt and ans[i] == None:
		ans[i] = ch1
		s1cnt -= 1
	elif s2cnt and ans[i] == None:
		ans[i] = ch2
		s2cnt -= 1
	elif ans[i] == None:
		for j in range(ord('a'), ord('e')):
			if chr(j) != ch1 and chr(j) != ch2:
				ans[i] = chr(j)
				break
if s1cnt or s2cnt:
	print(-1)
else:
	print(''.join(ans))


(n, t) = map(int, input().split())
s1 = input()
s2 = input()
diff = 0
same = 0
for i in range(len(s1)):
	if s1[i] != s2[i]:
		diff += 1
	else:
		same += 1
if diff > 2 * t:
	print(-1)
	exit()
ans = ['' for i in range(n)]
count = t
if diff <= t:
	for i in range(len(s1)):
		if s1[i] != s2[i]:
			if s1[i] != 'a' and s2[i] != 'a':
				ans[i] = 'a'
			elif s1[i] != 'b' and s2[i] != 'b':
				ans[i] = 'b'
			elif s1[i] != 'c' and s2[i] != 'c':
				ans[i] = 'c'
			count -= 1
		else:
			ans[i] = -1
	for i in range(len(s1)):
		if s1[i] == s2[i]:
			if count > 0:
				if s1[i] != 'a' and s2[i] != 'a':
					ans[i] = 'a'
				else:
					ans[i] = 'b'
				count -= 1
			else:
				ans[i] = s1[i]
	print(''.join(map(str, ans)))
else:
	ans = ['' for i in range(len(s1))]
	c1 = diff - t
	c2 = diff - t
	for i in range(len(s1)):
		if s1[i] != s2[i]:
			if c1:
				ans[i] = s1[i]
				c1 -= 1
			elif c2:
				ans[i] = s2[i]
				c2 -= 1
			elif s1[i] != 'a' and s2[i] != 'a':
				ans[i] = 'a'
			elif s1[i] != 'b' and s2[i] != 'b':
				ans[i] = 'b'
			elif s1[i] != 'c' and s2[i] != 'c':
				ans[i] = 'c'
		else:
			ans[i] = s1[i]
	print(''.join(map(str, ans)))


(n, t) = map(int, input().split())
r = input()
s = input()
u = len(s)
v = []
for i in range(len(s)):
	if r[i] != s[i]:
		v += [i]
m = len(v)
if t >= m:
	j = t - m
	for i in range(u):
		if r[i] != s[i]:
			if r[i] != 'a' and s[i] != 'a':
				print('a', end='')
			elif r[i] != 'b' and s[i] != 'b':
				print('b', end='')
			else:
				print('c', end='')
		elif j > 0:
			j -= 1
			if r[i] != 'a' and s[i] != 'a':
				print('a', end='')
			elif r[i] != 'b' and s[i] != 'b':
				print('b', end='')
			else:
				print('c', end='')
		else:
			print(s[i], end='')
elif m % 2 == 0:
	k = m // 2
	if t < k:
		print(-1)
	else:
		j = 2 * (t - k)
		jj = m - t
		for i in range(u):
			if r[i] == s[i]:
				print(s[i], end='')
			elif j > 0:
				j -= 1
				if r[i] != 'a' and s[i] != 'a':
					print('a', end='')
				elif r[i] != 'b' and s[i] != 'b':
					print('b', end='')
				else:
					print('c', end='')
			elif jj > 0:
				jj -= 1
				print(r[i], end='')
			else:
				print(s[i], end='')
else:
	k = (m - 1) // 2
	if t <= k:
		print(-1)
	else:
		t -= 1
		j = 2 * (t - k) + 1
		jj = 2 * k - t
		for i in range(u):
			if r[i] == s[i]:
				print(s[i], end='')
			elif j > 0:
				j -= 1
				if r[i] != 'a' and s[i] != 'a':
					print('a', end='')
				elif r[i] != 'b' and s[i] != 'b':
					print('b', end='')
				else:
					print('c', end='')
			elif jj > 0:
				jj -= 1
				print(r[i], end='')
			else:
				print(s[i], end='')


import itertools as ittls
from collections import Counter
from functools import reduce
import string
import math

def sqr(x):
	return x * x

def inputarray(func=int):
	return map(func, input().split())
(n, t) = inputarray()
s1 = input()
s2 = input()
d = sum(map(lambda x, y: x != y, s1, s2))
if t < (d + 1) // 2:
	print(-1)
	quit()

def nt(x, y):
	s = set(['a', 'b', 'c']) - set([x, y])
	return s.pop()
if t >= d:
	(res, v) = ('', 0)
	for (i, j) in zip(s1, s2):
		if i != j:
			res = res + nt(i, j)
		elif v < t - d:
			res = res + nt(i, j)
			v = v + 1
		else:
			res = res + i
	print(res)
else:
	(res, k) = ('', 0)
	for (i, j) in zip(s1, s2):
		if i == j:
			res = res + i
		else:
			if d == t:
				res = res + nt(i, j)
				t = t - 1
			else:
				if k == 0:
					res = res + i
					t = t - 1
				else:
					res = res + j
				k = 1 - k
			d = d - 1
	if d != 0 or t != 0:
		print(-1)
	else:
		print(res)


def main():
	(n, t) = map(int, input().split())
	(aa, bb) = (input(), input())
	z = sum((a != b for (a, b) in zip(aa, bb)))
	if t * 2 < z:
		print(-1)
		return
	(res, d, ascii) = ([], {}, tuple('abcdefghijklmnopqrstuvwxyz'))
	for a in ascii:
		for b in ascii:
			for c in ascii:
				if a != c != b:
					d[a, b] = c
					break
	if t >= z:
		t -= z
		for (a, b) in zip(aa, bb):
			if a == b:
				if t:
					res.append(d[a, b])
					t -= 1
				else:
					res.append(a)
			else:
				res.append(d[a, b])
	else:
		t = t * 2 - z
		flag = True
		for (a, b) in zip(aa, bb):
			if a == b:
				res.append(a)
			elif t:
				res.append(d[a, b])
				t -= 1
			else:
				res.append(a if flag else b)
				flag = not flag
	print(''.join(res))
main()


(n, t) = map(int, input().split())
s1 = input()
s2 = input()
sm = n - t
check = []
ans = ['#'] * n
same = 0
diff = 0
for i in range(n):
	if s1[i] == s2[i]:
		check.append(True)
		same += 1
	else:
		check.append(False)
		diff += 1
if same + diff // 2 < sm:
	print(-1)
else:
	i = 0
	t1 = t2 = sm
	while i < n and t1 and t2:
		if check[i]:
			ans[i] = s1[i]
			t1 -= 1
			t2 -= 1
		i += 1
	i = 0
	while i < n and t1:
		if ans[i] == '#':
			ans[i] = s1[i]
			t1 -= 1
		i += 1
	i = 0
	while i < n and t2:
		if ans[i] == '#':
			ans[i] = s2[i]
			t2 -= 1
		i += 1
	for i in range(n):
		if ans[i] == '#':
			if s1[i] != 'a' and s2[i] != 'a':
				ans[i] = 'a'
			elif s1[i] != 'b' and s2[i] != 'b':
				ans[i] = 'b'
			else:
				ans[i] = 'c'
	t1 = t2 = 0
	for i in range(n):
		if ans[i] != s1[i]:
			t1 += 1
		if ans[i] != s2[i]:
			t2 += 1
	if t == t1 == t2:
		print(''.join(ans))
	else:
		print(-1)


m = {chr(x): chr(x + 1) for x in range(97, 122)}
m['z'] = 'a'
(n, t) = map(int, input().split())
s1 = input()
s2 = input()
diffs = [True if s1[x] == s2[x] else False for x in range(n)]
same = diffs.count(True)
maximumDiffs = (n + same) // 2
if t < n - maximumDiffs:
	print('-1')
else:
	newStr = []
	matchingCharsPerString = n - t
	c = matchingCharsPerString - same
	if c < 0:
		evenToCorrect = abs(c)
		for (i, item) in enumerate(diffs):
			if item:
				if evenToCorrect > 0:
					newStr.append(m[s1[i]])
					evenToCorrect -= 1
				else:
					newStr.append(s1[i])
			else:
				candidate = m[s1[i]]
				if candidate == s2[i]:
					candidate = m[s2[i]]
				newStr.append(candidate)
	else:
		matchesLeft = c
		toggle = True
		for (i, item) in enumerate(diffs):
			if item:
				newStr.append(s1[i])
			elif matchesLeft:
				newStr.append([s2[i], s1[i]][toggle])
				toggle = not toggle
				if toggle:
					matchesLeft -= 1
			else:
				candidate = m[s1[i]]
				if candidate == s2[i]:
					candidate = m[s2[i]]
				newStr.append(candidate)
	print(''.join(newStr))


import os
import sys
from io import BytesIO, IOBase
import heapq as h
from bisect import bisect_left, bisect_right
from types import GeneratorType
BUFSIZE = 8192
from random import random

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		import os
		self.os = os
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = self.os.read(self._fd, max(self.os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = self.os.read(self._fd, max(self.os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			self.os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')
(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
input = lambda : sys.stdin.readline().rstrip('\r\n')
from collections import defaultdict as dd, deque as dq, Counter as dc
import math, string

def getInts():
	return [int(s) for s in input().split()]

def getInt():
	return int(input())

def getStrs():
	return [s for s in input().split()]

def getStr():
	return input()

def listStr():
	return list(input())

def getMat(n):
	return [getInts() for _ in range(n)]
MOD = 10 ** 9 + 7

def solve():
	(N, T) = getInts()
	T = N - T
	(A, B) = (getStr(), getStr())
	count = 0
	ans = [''] * N
	for i in range(N):
		if A[i] == B[i]:
			if count < T:
				ans[i] = A[i]
			else:
				ans[i] = 'a' if A[i] != 'a' else 'b'
			count += 1
	non = N - count
	count = min(count, T)
	if non < 2 * (T - count):
		return -1
	num = 0
	ops = ['a', 'b', 'c']
	for i in range(N):
		if ans[i] != '':
			continue
		if num < T - count:
			ans[i] = A[i]
		elif num < 2 * (T - count):
			ans[i] = B[i]
		else:
			for op in ops:
				if op not in [A[i], B[i]]:
					ans[i] = op
					break
		num += 1
	return ''.join(ans)
print(solve())


from sys import stdin, stdout
nmbr = lambda : int(stdin.readline())
lst = lambda : list(map(int, stdin.readline().split()))
for _ in range(1):
	(n, k) = lst()
	a = input()
	b = input()
	same = set()
	for i in range(n):
		if a[i] == b[i]:
			same.add(i)
	common = len(same)
	tobesame = n - k
	effec_same_needed = max(0, tobesame - common)
	effec_len = n - common
	if effec_same_needed * 2 > effec_len:
		print(-1)
	else:
		ans = [' '] * n
		vis = set()
		for ind in same:
			if tobesame == 0:
				break
			ans[ind] = a[ind]
			vis.add(ind)
			tobesame -= 1
		c = effec_same_needed
		for i in range(n):
			if i in vis:
				continue
			if c == 0:
				break
			ans[i] = a[i]
			vis.add(i)
			c -= 1
		c = effec_same_needed
		for i in range(n):
			if i in vis:
				continue
			if c == 0:
				break
			ans[i] = b[i]
			vis.add(i)
			c -= 1
		for i in range(n):
			if i in vis:
				continue
			for asc in range(97, 123):
				if chr(asc) not in [a[i], b[i]]:
					ans[i] = chr(asc)
					break
		print(''.join(ans))


(n, t) = list(map(int, input().split()))
(s1, s2) = (input(), input())

def f(s1, s2):
	ans = 0
	for i in range(len(s1)):
		if s1[i] != s2[i]:
			ans += 1
	return ans

def other(ch1, ch2):
	if ch1 != 'a' != ch2:
		return 'a'
	if ch1 != 'b' != ch2:
		return 'b'
	if ch1 != 'c' != ch2:
		return 'c'
if f(s1, s2) > t:
	ans = ''
	t1 = t2 = f(s1, s2) - t
	for i in range(n):
		if s1[i] == s2[i]:
			ans += s1[i]
			continue
		if t1 > 0:
			ans += s1[i]
			t1 -= 1
			continue
		if t2 > 0:
			ans += s2[i]
			t2 -= 1
			continue
		ans += other(s1[i], s2[i])
	if t1 != 0 or t2 != 0:
		print('-1')
		exit()
	print(ans)
	exit()
ans = ''
for i in range(n):
	if s1[i] != s2[i]:
		ans += other(s1[i], s2[i])
		continue
	ans += s1[i]
t -= f(s1, s2)
ans2 = ''
for i in range(n):
	if t > 0 and s1[i] == s2[i]:
		ans2 += other(s1[i], s2[i])
		t -= 1
		continue
	ans2 += ans[i]
print(ans2)


import os
import sys
from math import *
from collections import *
from fractions import *
from bisect import *
from heapq import *
from io import BytesIO, IOBase

def vsInput():
	sys.stdin = open('input.txt', 'r')
	sys.stdout = open('output.txt', 'w')
BUFSIZE = 8192

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')
(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
input = lambda : sys.stdin.readline().rstrip('\r\n')

def value():
	return tuple(map(int, input().split()))

def array():
	return [int(i) for i in input().split()]

def Int():
	return int(input())

def Str():
	return input()

def arrayS():
	return [i for i in input().split()]
(n, t) = value()
s1 = input()
s2 = input()
s3 = [0] * n
ot = t
dif = []
equal = []
for i in range(n):
	if s1[i] != s2[i]:
		dif.append(i)
	else:
		equal.append(i)
i = 0
while i + 1 < len(dif):
	s3[dif[i]] = 1
	s3[dif[i + 1]] = 2
	t -= 1
	i += 2
if len(dif) % 2:
	s3[dif[-1]] = 3
	t -= 1
i = 0
while t > 0 and i + 1 < len(dif):
	t -= 1
	s3[dif[i]] = 3
	s3[dif[i + 1]] = 3
	i += 2
i = 0
while t > 0 and i < len(equal):
	s3[equal[i]] = 3
	t -= 1
	i += 1
d1 = 0
d2 = 0
for i in range(n):
	if s1[i] == 1:
		s3[i] = s1[i]
	elif s3[i] == 2:
		s3[i] = s2[i]
	elif s3[i] == 3:
		for c in 'abc':
			if s1[i] != c and s2[i] != c:
				s3[i] = c
				break
	else:
		s3[i] = s1[i]
	d1 += s1[i] != s3[i]
	d2 += s2[i] != s3[i]
if d1 == d2 and d1 == ot:
	print(*s3, sep='')
else:
	print(-1)


def getDiffChar(c1, c2):
	if c1 != 'a' and c2 != 'a':
		return 'a'
	elif c1 != 'b' and c2 != 'b':
		return 'b'
	else:
		return 'c'
(n, t) = map(int, input().split())
s1 = input()
s2 = input()
diff = 0
for i in range(n):
	if s1[i] != s2[i]:
		diff += 1
same = n - diff
if t < diff / 2:
	ans = -1
elif t < diff:
	s3_list = []
	p1 = p2 = diff - t
	for i in range(n):
		if s1[i] == s2[i]:
			s3_list.append(s1[i])
		elif p1:
			s3_list.append(s1[i])
			p1 -= 1
		elif p2:
			s3_list.append(s2[i])
			p2 -= 1
		else:
			s3_list.append(getDiffChar(s1[i], s2[i]))
	s3 = ''.join(s3_list)
	ans = s3
else:
	s3_list = []
	p = t - diff
	for i in range(n):
		if s1[i] == s2[i]:
			if p:
				s3_list.append(getDiffChar(s1[i], s2[i]))
				p -= 1
			else:
				s3_list.append(s1[i])
		else:
			s3_list.append(getDiffChar(s1[i], s2[i]))
	s3 = ''.join(s3_list)
	ans = s3
print(ans)


def get_diff(a, b):
	res = 'a'
	while res == a or res == b:
		res = chr(ord(res) + 1)
	return res
(n, t) = map(int, input().split())
s1 = input()
s2 = input()
diff = 0
res = '-1'
for i in range(n):
	if s1[i] != s2[i]:
		diff += 1
if t < diff:
	if t * 2 >= diff:
		res = [None] * n
		singole = t * 2 - diff
		curr = 1
		for i in range(n):
			if s1[i] == s2[i]:
				res[i] = s1[i]
			elif singole > 0:
				res[i] = get_diff(s1[i], s2[i])
				singole -= 1
			else:
				if curr == 1:
					res[i] = s1[i]
				else:
					res[i] = s2[i]
				curr = -curr
elif t == diff:
	res = [None] * n
	for i in range(n):
		if s1[i] == s2[i]:
			res[i] = s1[i]
		else:
			res[i] = get_diff(s1[i], s2[i])
else:
	res = [None] * n
	for i in range(n):
		if s1[i] == s2[i]:
			if t > diff:
				res[i] = get_diff(s1[i], s2[i])
				t -= 1
			else:
				res[i] = s1[i]
		else:
			res[i] = get_diff(s1[i], s2[i])
res = ''.join(res)
print(res)


(n, k) = map(int, input().split())
a = input()
b = input()
cnt = 0
for i in range(n):
	if a[i] == b[i]:
		cnt += 1
dif = n - cnt
ok = n - (cnt + dif // 2)
if k < ok:
	print(-1)
else:
	(res, cur, req, i, nxt) = ({}, 0, n - k, 0, True)
	while cur < req:
		if a[i] == b[i]:
			(res[i], cur) = (a[i], cur + 1)
		elif nxt:
			(pos, nxt) = (i, not nxt)
		else:
			(res[pos], res[i], nxt, cur) = (a[pos], b[i], not nxt, cur + 1)
		i += 1
	if nxt == False:
		if 'a' != a[pos] and 'a' != b[pos]:
			res[pos] = 'a'
		elif 'b' != a[pos] and 'b' != b[pos]:
			res[pos] = 'b'
		elif 'c' != a[pos] and 'c' != b[pos]:
			res[pos] = 'c'
		else:
			res[pos] = 'd'
	while i < n:
		if 'a' != a[i] and 'a' != b[i]:
			res[i] = 'a'
		elif 'b' != a[i] and 'b' != b[i]:
			res[i] = 'b'
		elif 'c' != a[i] and 'c' != b[i]:
			res[i] = 'c'
		else:
			res[i] = 'd'
		i += 1
	for i in range(n):
		print(res[i], end='')


(n, t) = map(int, input().split())
s1 = list(input())
s2 = list(input())
s = list(s1)
dif_1_2 = 0
same_1_2 = 0
dif_place = []
same_place = []
for i in range(n):
	if s1[i] != s2[i]:
		dif_1_2 += 1
		dif_place.append(i)
	else:
		same_place.append(i)
same_ans_1 = len(s)
if dif_1_2 == t:
	for i in dif_place:
		if s1[i] != 'a' and s2[i] != 'a':
			s[i] = 'a'
		elif s1[i] != 'b' and s2[i] != 'b':
			s[i] = 'b'
		elif s1[i] != 'c' and s2[i] != 'c':
			s[i] = 'c'
	print(''.join(s))
	exit()
if dif_1_2 > t:
	if dif_1_2 > 2 * t:
		print(-1)
		exit()
	change_cnt = 0
	for i in dif_place:
		if dif_1_2 > t:
			if change_cnt % 2 == 0:
				s[i] = s1[i]
			else:
				s[i] = s2[i]
				dif_1_2 -= 1
			change_cnt += 1
		elif s1[i] != 'a' and s2[i] != 'a':
			s[i] = 'a'
		elif s1[i] != 'b' and s2[i] != 'b':
			s[i] = 'b'
		elif s1[i] != 'c' and s2[i] != 'c':
			s[i] = 'c'
	print(''.join(s))
	exit()
dif = dif_1_2
if dif_1_2 < t:
	for i in dif_place:
		if s1[i] != 'a' and s2[i] != 'a':
			s[i] = 'a'
		elif s1[i] != 'b' and s2[i] != 'b':
			s[i] = 'b'
		elif s1[i] != 'c' and s2[i] != 'c':
			s[i] = 'c'
	for i in same_place:
		if dif == t:
			break
		if s1[i] != 'a':
			s[i] = 'a'
		else:
			s[i] = 'b'
		dif += 1
	print(''.join(s))
	exit()


from sys import stdin
inp = lambda : stdin.readline().strip()
(n, t) = [int(x) for x in inp().split()]
a = inp()
b = inp()
ans = list(a[:])
diff = [i for i in range(n) if a[i] != b[i]]
while t:
	if len(diff) <= t:
		break
	i = diff.pop()
	ans[i] = a[i]
	i = diff.pop()
	ans[i] = b[i]
	t -= 1
while len(diff) > 0 and t > 0:
	i = diff.pop()
	ans[i] = [x for x in 'abc' if x != a[i] and x != b[i]][0]
	t -= 1
if t:
	for i in range(n):
		if a[i] == b[i]:
			ans[i] = [x for x in 'ab' if x != a[i]][0]
			t -= 1
			if not t:
				break
if t > 0 or len(diff) > 0:
	print(-1)
else:
	print(''.join(ans))


import sys
(n, t) = map(int, sys.stdin.readline().split())
ans = ['*' for _ in range(n)]
all = 'abcdefghijklmnopqrstuvwxyz'
strings = tuple([sys.stdin.readline().replace('\n', ''), sys.stdin.readline().replace('\n', '')])
s = n - t
for i in range(n):
	if s != 0 and strings[0][i] == strings[1][i]:
		ans[i] = strings[0][i]
		s -= 1
	if s == 0:
		break
turn = 0
s = s * 2
t = t * 2
for i in range(n):
	if s != 0 and ans[i] == '*':
		if strings[0][i] != strings[1][i]:
			ans[i] = strings[turn][i]
		else:
			ans[i] = all.replace(strings[turn][i], '')[0]
		turn = (turn + 1) % 2
		t -= 1
		s -= 1
	if s == 0 and ans[i] == '*':
		new = all.replace(strings[0][i], '')
		new = new.replace(strings[1][i], '')
		ans[i] = new[0]
		t -= 2
if s == 0 and t == 0:
	print(''.join(ans))
else:
	print(-1)


from sys import stdin, stdout
from collections import defaultdict
import math

def other(a, b):
	x = a
	for i in range(26):
		c = chr(ord('a') + i)
		if c != a and c != b:
			return c
mod = 10 ** 9 + 7
I = stdin.readline
P = stdout.write
(n, t) = map(int, I().split())
s1 = I().rstrip()
s2 = I().rstrip()
b = n - t
a = 0
same = []
for i in range(n):
	if s1[i] == s2[i]:
		a += 1
		same.append(i)
ans = ['0' for i in range(n)]
if a >= b:
	for i in range(b):
		ans[same[i]] = s1[same[i]]
	for i in range(n):
		if ans[i] == '0':
			ans[i] = other(s1[i], s2[i])
	print(''.join(ans))
else:
	for j in same:
		ans[j] = s1[j]
	if 2 * (b - a) <= n - a:
		now1 = b - a
		(k, l) = (0, 0)
		for i in range(n):
			if ans[i] == '0':
				if k < now1:
					ans[i] = s1[i]
					k += 1
				elif l < now1:
					ans[i] = s2[i]
					l += 1
				else:
					ans[i] = other(s1[i], s2[i])
		print(''.join(ans))
	else:
		print(-1)


import sys
import time
t1 = time.time()
from string import ascii_lowercase as lc
(n, t) = map(int, input().split())
s1 = input()
s2 = input()
ctr = 0
for i in range(n):
	if s1[i] != s2[i]:
		ctr += 1
(ctr1, ctr2) = (ctr - t, ctr - t)
if t >= ctr / 2:
	ans = []
	if t > ctr:
		for i in range(n):
			if s1[i] == s2[i]:
				if t > ctr:
					if s1[i] == 'a':
						ans.append('b')
					else:
						ans.append('a')
					t -= 1
				else:
					ans.append(s1[i])
			else:
				for j in range(3):
					if lc[j] != s1[i] and lc[j] != s2[i]:
						ans.append(lc[j])
						break
	else:
		for i in range(n):
			if s1[i] == s2[i]:
				ans.append(s1[i])
			elif ctr1 != 0:
				ans.append(s1[i])
				ctr1 -= 1
			elif ctr2 != 0:
				ans.append(s2[i])
				ctr2 -= 1
			else:
				for j in range(3):
					if lc[j] != s1[i] and lc[j] != s2[i]:
						ans.append(lc[j])
						break
	print(''.join((a1 for a1 in ans)))
else:
	print(-1)


fs = frozenset(list('abc'))

def calc(s1, s2):
	return len(list(filter(lambda x: x[0] == x[1], zip(s1, s2))))
(n, t) = map(int, input().split())
s1 = input()
s2 = input()
q = n - t
c = calc(s1, s2)
need = q - c
w = 0
ss = ['x'] * len(s1)
if n - c >= 2 * need:
	for i in range(len(s1)):
		ss[i] = list(fs - frozenset(s1[i]) - frozenset(s2[i]))[0]
		if s1[i] == s2[i]:
			ss[i] = s1[i]
		if s1[i] == s2[i] and need < 0 and (w > need):
			w -= 1
			ss[i] = list(fs - frozenset(s1[i]) - frozenset(s2[i]))[0]
		if s1[i] != s2[i] and need > 0 and (w < 2 * need):
			if w >= need:
				ss[i] = s2[i]
			else:
				ss[i] = s1[i]
			w += 1
	print(''.join(ss))
else:
	print('-1')


(n, t) = map(int, input().split())
s1 = input()
s2 = input()
same = n - t
poss = []
left = []
s = [0 for _ in range(n)]
for i in range(n):
	if s1[i] == s2[i]:
		poss.append(i)
	else:
		left.append(i)
if len(poss) >= same:
	for i in range(same):
		s[poss[i]] = s1[poss[i]]
	for i in range(n):
		if s[i] == 0:
			for j in range(26):
				if chr(j + 97) != s1[i] and chr(j + 97) != s2[i]:
					s[i] = chr(j + 97)
					break
	ans = ''
	for i in s:
		ans += i
	print(ans)
else:
	for i in range(min(same, len(poss))):
		s[poss[i]] = s1[poss[i]]
	rem = n - t - len(poss)
	for i in range(n):
		if s[i] == 0:
			s[i] = s1[i]
			rem -= 1
		if rem == 0:
			break
	if rem != 0:
		print(-1)
		exit(0)
	rem = n - t - len(poss)
	for i in range(n):
		if s[i] == 0:
			s[i] = s2[i]
			rem -= 1
		if rem == 0:
			break
	if rem != 0:
		print(-1)
		exit(0)
	for i in range(n):
		if s[i] == 0:
			for j in range(26):
				if chr(j + 97) != s1[i] and chr(j + 97) != s2[i]:
					s[i] = chr(j + 97)
					break
	ans = ''
	for i in s:
		ans += i
	print(ans)


def f(sa, sb):
	ans = 0
	for i in range(len(sa)):
		ans += sa[i] != sb[i]
	return ans

def third(a0, b0):
	if a0 != 'a' and b0 != 'a':
		return 'a'
	if a0 != 'b' and b0 != 'b':
		return 'b'
	if a0 != 'c' and b0 != 'c':
		return 'c'
(n, t) = list(map(int, input().split()))
s1 = input()
s2 = input()
sovp = n - f(s1, s2)
needsovp = n - t
ans = [0] * n
need1r = needsovp - sovp
need2r = needsovp - sovp
if sovp >= needsovp:
	for i in range(n):
		if s1[i] != s2[i]:
			ans[i] = third(s1[i], s2[i])
		elif needsovp > 0:
			ans[i] = s1[i]
			needsovp -= 1
		else:
			ans[i] = third(s1[i], s2[i])
	if not f(''.join(ans), s1) == f(''.join(ans), s2) == t:
		print(-1)
	else:
		print(*ans, sep='')
else:
	for i in range(n):
		if s1[i] != s2[i]:
			if need1r > 0:
				need1r -= 1
				ans[i] = s1[i]
			elif need2r > 0:
				need2r -= 1
				ans[i] = s2[i]
			else:
				ans[i] = third(s1[i], s2[i])
		else:
			ans[i] = s1[i]
	if not f(''.join(ans), s1) == f(''.join(ans), s2) == t:
		print(-1)
	else:
		print(*ans, sep='')


import sys
letras = 'abcdefghijklmnopqrstuvwxyz'

def distinto(a, b):
	for lc in range(26):
		c = letras[lc]
		if a != c and b != c:
			return c
s3 = ''
l = 0
for line in sys.stdin:
	if l == 0:
		(n, t) = map(int, line.split())
	if l == 1:
		s1 = line
	else:
		s2 = line
	l += 1
dist = 0
for i in range(n):
	if s1[i] != s2[i]:
		dist += 1
if t < int((dist + 1) / 2):
	s3 += str(-1)
elif t >= dist:
	igdist = t - dist
	for i in range(n):
		if s1[i] != s2[i]:
			s3 += distinto(s1[i], s2[i])
		elif igdist == 0:
			s3 += s1[i]
		else:
			s3 += distinto(s1[i], s2[i])
			igdist -= 1
else:
	distdist = dist - t
	alter = 1
	for i in range(n):
		if s1[i] == s2[i]:
			s3 += s1[i]
		elif distdist == 0:
			s3 += distinto(s1[i], s2[i])
		elif alter == 1:
			s3 += s1[i]
			alter = 2
		else:
			s3 += s2[i]
			alter = 1
			distdist -= 1
print(s3)


from random import choice
letters = [chr(letter) for letter in range(ord('a'), ord('z') + 1)]

def solve(n, t, s1, s2):
	same_char_count = n - t
	c = sum((char1 == char2 for (char1, char2) in zip(s1, s2)))
	if same_char_count <= c:
		s3 = list(s1)
		count = 0
		for i in range(len(s1)):
			if s1[i] == s2[i] and count < same_char_count:
				count += 1
				pass
			else:
				while True:
					char = choice(letters)
					if char != s1[i] and char != s2[i]:
						s3[i] = char
						break
		print(''.join(s3))
		return
	else:
		s4 = list(s1)
		(count1, count2) = (0, 0)
		for i in range(len(s1)):
			if s1[i] != s2[i]:
				if count1 < count2 and count1 < same_char_count - c:
					s4[i] = s1[i]
					count1 += 1
				elif count2 <= count1 and count2 < same_char_count - c:
					s4[i] = s2[i]
					count2 += 1
				else:
					while True:
						char = choice(letters)
						if char != s1[i] and char != s2[i]:
							s4[i] = char
							break
		c1 = sum((char1 == char2 for (char1, char2) in zip(s1, s4)))
		c2 = sum((char1 == char2 for (char1, char2) in zip(s2, s4)))
		if c1 == same_char_count and c2 == same_char_count:
			print(''.join(s4))
			return
	print(-1)
(n, t) = map(int, input().split())
s1 = input()
s2 = input()
solve(n, t, s1, s2)


from sys import stdin

def get_different(a, b):
	for i in range(97, 97 + 26):
		if chr(i) not in [a, b]:
			return chr(i)
(n, t) = list(map(int, stdin.readline().split()))
first = stdin.readline().strip()
second = stdin.readline().strip()
diff = 0
same = 0
for i in range(n):
	if first[i] == second[i]:
		same += 1
	else:
		diff += 1
if diff % 2 == 0:
	mn = diff // 2
else:
	mn = diff // 2 + 1
if t < mn:
	print(-1)
	exit()
ans = [0] * n
i = 0
flag = True
while diff > t and i < n:
	if first[i] != second[i]:
		if flag:
			ans[i] = first[i]
			flag = False
		else:
			ans[i] = second[i]
			flag = True
			diff -= 2
			t -= 1
	i += 1
i = 0
while t > 0 and diff > 0 and (i < n):
	if first[i] != second[i] and ans[i] == 0:
		ans[i] = get_different(first[i], second[i])
		diff -= 1
		t -= 1
	i += 1
i = 0
while t > 0 and i < n:
	if first[i] == second[i] and ans[i] == 0:
		ans[i] = get_different(first[i], first[i])
		same -= 1
		t -= 1
	i += 1
for i in range(n):
	if ans[i] == 0:
		ans[i] = first[i]
print(''.join(ans))


(n, t) = tuple(map(int, input().split()))
s1 = input()
s2 = input()
dif = []
same = []
for i in range(n):
	if s1[i] != s2[i]:
		dif.append(i)
	else:
		same.append(i)
s3 = list(s2)
if len(dif) > 2 * t or t > n:
	print(-1)
	exit(0)
l = len(dif)
if len(dif) <= t:
	for i in dif:
		s3[i] = 'a'
		if s1[i] == 'a' or s2[i] == 'a':
			s3[i] = 'b'
			if s1[i] == 'b' or s2[i] == 'b':
				s3[i] = 'c'
	for i in range(t - l):
		a = same[i]
		s3[a] = 'a'
		if s1[a] == 'a':
			s3[a] = 'b'
else:
	for i in range(l - t):
		a = dif[i]
		s3[a] = s1[a]
	for i in range(l - t, 2 * (l - t)):
		a = dif[i]
		s3[a] = s2[a]
	for a in range(2 * (l - t), l):
		i = dif[a]
		s3[i] = 'a'
		if s1[i] == 'a' or s2[i] == 'a':
			s3[i] = 'b'
			if s1[i] == 'b' or s2[i] == 'b':
				s3[i] = 'c'
print(''.join(s3))