#imports
import sys

# input  the initial string
s = input().strip()
# input the desired final string
t = input().strip()
# input  the number of operations
k = int(input().strip())

lead = 0
for i in range(min(len(s),len(t))):
    if s[i] != t[i]:
        lead = i
        break
    else:
        lead = i + 1
        
d = len(s) - lead + len(t) - lead
# Print either Yes or No
if k >= len(s) + len(t):
    print("Yes")
elif d <= k and (d % 2) == (k % 2):
    print("Yes")
else:
    print("No")