#include <bits/stdc++.h>

using namespace std;
typedef long long ll;

int n, m, p;
int a[8][8][8];

bool check() {
  for (int i = 0; i < n; i++) {
    for (int j = 0; j < n; j++) {
      for (int k = 0; k < n; k++) {
        int c = a[i][j][k];
        if (c == 0) continue;
        for (int di = -1; di <= 1; di++) {
          for (int dj = -1; dj <= 1; dj++) {
            for (int dk = -1; dk <= 1; dk++) {
              if (di == 0 && dj == 0 && dk == 0) continue;
              int ni = i + di * (m - 1), nj = j + dj * (m - 1), nk = k + dk * (m - 1);
              if (ni >= 0 && ni < n && nj >= 0 && nj < n && nk >= 0 && nk < n) {
                bool res = true;
                for (int l = 0; l < m; l++) {
                  res &= a[i + di * l][j + dj * l][k + dk * l] == c;
                }
                if (res) return true;
              }
            }
          }
        }
      }
    }
  }
  return false;
}

int main() {
  cin.tie(0);
  ios_base::sync_with_stdio(false);
  
  while (cin >> n >> m >> p, n) {
    fill(a[0][0], a[7][7], 0);
    int x, y;
    int win = 0, cnt = 0, turn = 1;
    for (int i = 0; i < p; i++) {
      cin >> x >> y;
      x--, y--;
      int h = 0;
      while (a[x][y][h] != 0) h++;
      a[x][y][h] = turn;
      if (win == 0 && check()) win = turn, cnt = i + 1;
      turn *= -1;
    }
    if (win == 0) cout << "Draw" << endl;
    else cout << (win > 0 ? "Black" : "White") << " " << cnt << endl;
  }

  return 0;
}
