Go

No attempts yetTime limit1sMemory limit128 MB

Problem

In the game of Go, two players alternate placing black and white stones on the lattice points of an n×nn \times n grid, each trying to surround as much territory (that is, regions of empty lattice points) as possible. At the end of the game, each player's score is the total area of the territory surrounded by their stones. Given the final positions of the black and white stones, compute each player's score and determine the winner.

Formally, two lattice points (r,c)(r, c) and (r,c)(r', c') are adjacent if rr+cc=1|r - r'| + |c - c'| = 1. A connected region of empty lattice points belongs to a player's territory if every adjacent occupied lattice point holds a stone of that player (see Figure 1). A player's score is the number of empty lattice points in their territory.

Figure 1: A 9×99 \times 9 Go board. Empty lattice points in black's territory are marked B, and those in white's territory are marked W. Neutral empty lattice points are left unmarked. Here white wins by 213=1821 - 3 = 18.

Note: this scoring does not correspond exactly to real Go. We assume all disputes have been settled, so that every region of territory is surrounded by stones of a single color.

Input

The input contains multiple test cases. Each test case consists of three lines.

  • The first line contains three integers nn (1n191 \le n \le 19), bb, and ww (b0b \ge 0, w0w \ge 0, and 1b+wn21 \le b + w \le n^2): the board size, the number of black stones, and the number of white stones.
  • The second line contains bb pairs of integers r1 c1  rb cbr_1\ c_1\ \dots\ r_b\ c_b (with 1ri,cin1 \le r_i, c_i \le n), the positions of the black stones.
  • The third line contains ww pairs of integers r1 c1  rw cwr'_1\ c'_1\ \dots\ r'_w\ c'_w (with 1ri,cin1 \le r'_i, c'_i \le n), the positions of the white stones.

No two stones occupy the same lattice point. When b=0b = 0 (or w=0w = 0), the corresponding line is empty. The input ends with a line containing a single 00, which must not be processed.

Output

For each test case, print one line. Let XX be the positive difference between the two scores. Print White wins by X if white has the higher score, Black wins by X if black has the higher score, or Draw if the scores are equal.