import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; public class No82 { public static void main(String[] args) throws IOException{ String[] str = new BufferedReader(new InputStreamReader(System.in)).readLine().split(" "); int w = Integer.parseInt(str[0]); int h = Integer.parseInt(str[1]); String[][] ichimatsu = new String[h][w]; ichimatsu[0][0] = str[2]; if(ichimatsu[0][0].equals("B")){ for(int i=0; i < w; i++) for(int j=1; j < h; j+=2) ichimatsu[j][i] = "W"; for(int i=0; i < w; i++) for(int j=2; j < h; j+=2) ichimatsu[j][i] = "B"; } else{ for(int i=0; i < w; i++) for(int j=1; j < h; j+=2) ichimatsu[j][i] = "B"; for(int i=0; i < w; i++) for(int j=2; j < h; j+=2) ichimatsu[j][i] = "W"; } if(ichimatsu[0][0].equals("B")){ for(int i=0; i < h; i++) for(int j=1; j < w; j+=2) ichimatsu[i][j] = "W"; for(int i=0; i < h; i++) for(int j=2; j < w; j+=2) ichimatsu[i][j] = "B"; } else{ for(int i=0; i < h; i++) for(int j=1; j < w; j+=2) ichimatsu[i][j] = "B"; for(int i=0; i < h; i++) for(int j=2; j < w; j+=2) ichimatsu[i][j] = "W"; } for(int i=0; i < h; i++){ for(int j=0; j < w; j++){ System.out.print(ichimatsu[i][j]); } System.out.println(""); } } }