h, w = [ int(v) for v in input().split() ] n = int(input()) rotate_list = [] for i in range(n): rotate_list.append(input()) y, x = 0, 0 for i in range(n): s = rotate_list[n-1-i] ope, target = s.split(" ") if int(target) == x: if ope == "R": x = (x-1) % w if int(target) == y: if ope == "C": y = (y-1) % h if (x + y) % 2 == 0: print("white") else: print("black")