#include <bits/stdc++.h>
#define For(i, a, b) for(int (i)=(int)(a); (i)<(int)(b); ++(i))
#define rFor(i, a, b) for(int (i)=(int)(a)-1; (i)>=(int)(b); --(i))
#define rep(i, n) For((i), 0, (n))
#define rrep(i, n) rFor((i), (n), 0)
#define fi first
#define se second
using namespace std;
typedef long long lint;
typedef unsigned long long ulint;
typedef pair<int, int> pii;
typedef pair<int, lint> pil;
typedef pair<lint, lint> pll;
template<class T> bool chmax(T &a, const T &b){if(a<b){a=b; return true;} return false;}
template<class T> bool chmin(T &a, const T &b){if(a>b){a=b; return true;} return false;}
template<class T> T div_floor(const T a, const T b){return a>=0 ? a/b : (a+1)/b-1;}
template<class T> T div_ceil(const T a, const T b){return a>=0 ? (a-1)/b+1 : a/b;}

constexpr lint mod = 1e9+7;
constexpr lint INF = mod*mod;
constexpr int MAX = 100010;

int dx[13] = {1, 0, 0, 1, -1, 1, -1, 0, 0, 1, 1, 1, 1};
int dy[13] = {0, 1, 0, 1, 1, 0, 0, 1, -1, 1, 1, -1, -1};
int dz[13] = {0, 0, 1, 0, 0, 1, 1, 1, 1, 1, -1, 1, -1};

int n, m, p;
using board = vector<vector<vector<int>>>;

bool in(int x, int y, int z){
    return 0<=x && x<n && 0<=y && y<n && 0<=z && z<n;
}

bool check(board &b, int x, int y, int z, int c){
    vector<int> cnt(13, -1);
    rep(i, 13)rep(j, 2){
        int tx = x, ty = y, tz = z;
        int sgn = j*2-1;
        int tmp = 0;
        rep(_, m){
            if(!in(tx, ty, tz) || b[tx][ty][tz] != c){
                break;
            }
            ++tmp;
            tx += sgn * dx[i];
            ty += sgn * dy[i];
            tz += sgn * dz[i];
        }
        cnt[i] += tmp;
    }
    return *max_element(cnt.begin(), cnt.end()) >= m;
}

int main(){
    while(scanf("%d%d%d", &n, &m, &p) && n){
        board b(n, vector<vector<int>>(n, vector<int>(n, -1)));
        vector<vector<int>> h(n, vector<int>(n, 0));
        int x[p], y[p];
        rep(i, p){
            scanf("%d%d", &x[i], &y[i]);
            --x[i], --y[i];
        }
        bool flag = false;
        rep(i, p){
            b[x[i]][y[i]][h[x[i]][y[i]]++] = i % 2;
            if(check(b, x[i], y[i], h[x[i]][y[i]]-1, i%2)){
                printf("%s %d\n", i%2==0 ? "Black" : "White", i+1);
                flag = true;
                break;
            }
        }
        if(!flag) puts("Draw");
    }
}
