#include #include #include #include #include #include #include using namespace std; #define diff(x,y) ((x > y) ? (x - y) : (y - x)) #define us(x) (x > 0) ? x : x * -1 #define lli long long int #define Black 'B' #define White 'W' int main() { int w, h; char c; bool bw; cin >> w >> h >> c; if (c == Black) bw = false; else bw = true; for (int i = 0; i < h; i++) { for (int j = 0; j < w; j++) { if (bw) cout << White; else cout << Black; bw = bw ? false : true; } if (w % 2 == 0) bw = bw ? false : true; cout << endl; } return 0; }