#include #include #include #include #include #include #include #include #include #define rep(i, a) FOR(i, 0, a) #define FOR(i, a, b) for(int i = a; i < b; ++i) typedef long long ll; typedef unsigned long long ull; typedef std::pair P; struct edge{ int to, time, cost; }; int main(){ int w, h; char a; std::cin >> w >> h >> a; rep(i, h){ rep(j, w){ std::cout << a; a = (a == 'W' ? 'B' : 'W'); } if (w % 2 == 0)a = (a == 'W' ? 'B' : 'W'); std::cout << std::endl; } return 0; }