import sys input = lambda : sys.stdin.readline().rstrip() sys.setrecursionlimit(2*10**5+10) write = lambda x: sys.stdout.write(x+"\n") debug = lambda x: sys.stderr.write(x+"\n") U = 0 D = 1 L = 2 R = 3 d = { U: "U", D:"D", L:"L", R:"R" } H,W,x = list(map(int, input().split())) h = (H+1)//2 w = (W+1)//2 M = h*w-1 if h*w%4==0 else h*w if not (H+W-2<=x<=2*(M-1) and x%2==0 and (x-(H+W-2))%4==0): print(-1) else: ans = [[0]*W for _ in range(H)] for i in range(1,H,2): for j in range(1,W,2): ans[i][j] = 1 for i in range(H): for j in range(1,W,2): ans[i][j] = 1 vals = [] def sub0(h,w,v): if w==2: if v%2==1: return None nokori = h-1 i = 0 j = W-2 while v>0: v -= 2 vals.extend([R, D, L, D]) ans[i][j] = 0 ans[i+2][j] = 0 ans[i+1][j-1] = 1 ans[i+3][j+1] = 1 nokori -= 1 i += 4 for _ in range(nokori): vals.append(D) vals.append(R) ans[-1][W-2] = 0 return 0 else: vals.extend([D]*(h-1)+[R]) ans[-1][W-2*(w-1)] = 0 # print(vals, W-2*(w-1)) return sub1(h,w-1,v) def sub1(h,w,v): if v==0: vals.extend([R]*(w-1)) for j in range(W-2*(w-1), W): ans[-1][j] = 0 return 0 elif v<=2*(h-1): # assert w>=2 and v%2==0 vv = v//2 vals.extend([U]*vv) vals.append(R) vals.extend([D]*vv) vals.extend([R]*(w-2)) ans[H-1-vv*2][W-2*w+2] = 0 # print(vv) for j in range(W-2*w+4,W): ans[-1][j] = 0 return 0 else: vals.extend([U]*(h-1)) vals.append([R]) ans[0][W-2*(w-1)] = 0 return sub0(h,w-1,v-2*(h-1)) v = x//2-(h-1+w-1) sub0(h,w,v) for l in ans: write("".join(["#" if l[i] else "." for i in range(len(l))]))