from sys import stdin def solve(): IN = map(lambda x: x.split(),stdin.readlines()) H,W = map(int,IN[0]) N = int(IN[1][0]) hx = hy = 0 for i in xrange(N+1,1,-1): s,k = IN[i]; k = int(k) if s == "R": if k == hy: hx = (hx - 1) % W else: if k == hx: hy = (hy - 1) % H print "white" if (hx + hy) % 2 == 0 else "black" solve()