c1,c2,n = input().split() n = int(n) if c1==c2: if n==1: print(c1) else: print(c1+"a"*(n-2)+c2) else: if n==1: print(-1) else: print(c1+"a"*(n-2)+c2)