#include <iostream>
using namespace std;

int main() {
	int w, h;
	char c;
	cin >> w >> h >> c;
	for (int i = 0; i < h; ++i) {
		for (int j = 0; j < w; ++j)
			cout << ((c == 'B') == ((i + j) % 2 == 0) ? 'B' : 'W');
		cout << endl;
	}
}