import java.io.InputStreamReader; public class Main { public static void main(String[] args) throws Exception { try (InputStreamReader isr = new InputStreamReader(System.in)) { StringBuilder sb = new StringBuilder(20_000_000); char[] cbuf = new char[10000]; int size; while ((size = isr.read(cbuf)) >= 0) { sb.append(cbuf, 0, size); } String[] lines = sb.toString().split("\n"); String[] ary = lines[0].trim().split(" "); int h = Integer.parseInt(ary[0]); int w = Integer.parseInt(ary[1]); int x = 0; int y = 0; for (int i = lines.length - 1; i >= 2; i--) { String line = lines[i].trim(); int k = Integer.parseInt(line.substring(2)); if (line.charAt(0) == 'R') { if (k == y) { x--; if (x < 0) x = w - 1; } } else { if (k == x) { y--; if (y < 0) y = h - 1; } } // System.err.println(String.format("%s (%d, %d)", line, x, y)); } System.out.println((x + y) % 2 == 0 ? "white" : "black"); } } }