import sys ARR = sys.stdin.read().splitlines() H,W = ARR[0].split() H = int(H) W = int(W) N = ARR[1] N = int(N) hx = hy = 0 for i in xrange(N-1,-1,-1): s,k = ARR[i+2].split() k = int(k) if s == "R": if k == hy: hx = hx - 1 if hx == -1: hx = W - 1 else: if k == hx: hy = hy - 1 if hy == -1: hy = H - 1 print "white" if (hx + hy) % 2 == 0 else "black"