w,h,s = input().split()
l = ''

#print(ord('B'),ord('W'))

for i in range(int(h)):
	for j in range(int(w)):
		l += s
		s = chr(153 - ord(s))
	print(l)
	l = ''
	if int(w)%2==0: s = chr(153 - ord(s))