w,h,c=input().split()
if c=="B":
    d="BW"
    e="W"
    f="WB"
else:
    d="WB"
    e="B"
    f="BW"
w=int(w)
h=int(h)
a=w%2
b=w//2
if a==1:
    s=d*b+c+"\r\n"
    t=f*b+e+"\r\n"
else:
    s=d*b+"\r\n"
    t=f*b+"\r\n"
p=h%2
q=h//2
if p==1:
    l=(s+t)*q+s
else:
    l=(s+t)*q
print(l)
"""        
w,h,c=input().split()
w=int(w)
h=int(h)
q=w*h//2
if c=="B":
    d="BW"
else:
    d="WB"
s=""
if w*h%2==1:
    s=d*q+c
else:
    s=d*q
t=""
print(s)
for i in range(0,w*h-w+1,w):
    t=t+s[i:i+w]+'\r\n'
    
print(t)
"""