import java.util.Scanner; public class pre { public static void main(String[] args) { Scanner s = new Scanner(System.in); int w = s.nextInt(),h = s.nextInt(); String c = s.next(); String[] str = new String[w*h]; for(int i=0;i= w && i%w == 0 && str[i-1].equals("B") && w%2 == 0){ str[i] = "B"; } else if(i >= w && i%w == 0 && str[i-1].equals("W") && w%2 == 0){ str[i] = "W"; } else if(c.equals("B")){ str[i] = c; c = "W"; } else if(c.equals("W")){ str[i] = c; c = "B"; } } int cnt=0; for(int i=0;i