s, e, N = input().split() N = int(N) if N == 1: if s == e: print(s) else: print(-1) else: print(s + ("a" * (N - 2) + e))