def seachPrimeNum(N): max = int(N**0.5) seachList = [i for i in range(2,N+1)] primeNum = [] while seachList[0] <= max: primeNum.append(seachList[0]) tmp = seachList[0] seachList = [i for i in seachList if i % tmp != 0] primeNum.extend(seachList) return primeNum # 素因数の数 def n_factorization(x): cnt = 0 for p in PL: if x in PL: cnt += 1 return cnt while x % p == 0: cnt += 1 x //= p if x == 1: return cnt # ここには来ないはず print("factorization error") return "error" N = int(input()) A = list(map(int,input().split())) PL = set(seachPrimeNum(max(max(A),2))) G = 0 for i in range(N): if A[i] != 1: G ^= (n_factorization(A[i])) if G == 0: print("black") else: print("white")