W,H,C=input(). split () W=int(W) H=int(H) if C=="B": D="W" else: D="B" Bo=[[C]*W]*H for i in range (H): for i in range (W): N=i+j if N%2==1: Bo[i][j]=D for i in range (H): print("".join(Bo[i]))