#include<iostream>
#include<stdio.h>
#include<algorithm>
#include<vector>
#include<string.h>
#include<math.h>
#include<map>
#include<iomanip>
#include<queue>

const long long INF = 1e6+7;
const long long MOD = 1e9+7;
const double PI=acos(-1);

using namespace std;

int main(){
	int w,h;
	cin >> w >> h;
	char c;
	cin >> c;
	vector<char> cc;
	cc.push_back(c);
	if(c=='W'){
		cc.push_back('B');
	}else{
		cc.push_back('W');
	}
	for(int i=0;i<h;i++){
		for(int j=0;j<w;j++){
			cout << cc[(j+i)%2];
		}
		cout << endl;
	}
	return 0;
}