#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
#define all(x) (x).begin(),(x).end()
const int mod=1000000007,MAX=105;
const ll INF=1LL<<62;

int main(){
    
    std::ifstream in("text.txt");
    std::cin.rdbuf(in.rdbuf());
    cin.tie(0);
    ios::sync_with_stdio(false);
    
    int N,u,v,M;cin>>N>>u>>v>>M;
    vector<int> cnt1h(N),cnt1w(N),cnt2h(N),cnt2w(N);
    int cnt1=0,cnt2=0,cnt1x=0,cnt1y=0,cnt2x=0,cnt2y=0;
    vector<pair<int,int>> where1(1000000,{-1,-1}),where2(1000000,{-1,-1});
    
    for(int i=0;i<N;i++){
        for(int j=0;j<N;j++){
            int a;cin>>a;
            a--;
            where1[a]={i,j};
        }
    }
    
    for(int i=0;i<N;i++){
        for(int j=0;j<N;j++){
            int a;cin>>a;
            a--;
            where2[a]={i,j};
        }
    }
    
    if(N==1){
        while(M--){
            int a,h,w;cin>>a;
            a--;
            
            if(where1[a].first>=0){
                h=where1[a].first;
                w=where1[a].second;
                
                cnt1h[h]++;
                cnt1w[w]++;
                if(h==w) cnt1x++;
                if(h+w==N-1) cnt1y++;
                
                if(cnt1h[h]==N) cnt1++;
                //if(cnt1w[w]==N) cnt1++;
                //if(h==w&&cnt1x==N) cnt1++;
                //if(h+w==N-1&&cnt1y==N) cnt1y++;
            }
            
            if(where2[a].first>=0){
                h=where2[a].first;
                w=where2[a].second;
                
                cnt2h[h]++;
                cnt2w[w]++;
                if(h==w) cnt2x++;
                if(h+w==N-1) cnt2y++;
                
                if(cnt2h[h]==N) cnt2++;
                //if(cnt2w[w]==N) cnt2++;
                //if(h==w&&cnt2x==N) cnt2++;
                //if(h+w==N-1&&cnt2y==N) cnt2y++;
            }
            
            if(cnt1>=u&&cnt2>=v){
                cout<<"DRAW"<<endl;
                return 0;
            }else if(cnt1>=u){
                cout<<"USAGI"<<endl;
                return 0;
            }else if(cnt2>=v){
                cout<<"NEKO"<<endl;
                return 0;
            }
        }
        
        cout<<"DRAW"<<endl;
        return 0;
    }
    
    while(M--){
        int a,h,w;cin>>a;
        a--;
        
        if(where1[a].first>=0){
            h=where1[a].first;
            w=where1[a].second;
            
            cnt1h[h]++;
            cnt1w[w]++;
            if(h==w) cnt1x++;
            if(h+w==N-1) cnt1y++;
            
            if(cnt1h[h]==N) cnt1++;
            if(cnt1w[w]==N) cnt1++;
            if(h==w&&cnt1x==N) cnt1++;
            if(h+w==N-1&&cnt1y==N) cnt1++;
        }
        
        if(where2[a].first>=0){
            h=where2[a].first;
            w=where2[a].second;
            
            cnt2h[h]++;
            cnt2w[w]++;
            if(h==w) cnt2x++;
            if(h+w==N-1) cnt2y++;
            
            if(cnt2h[h]==N) cnt2++;
            if(cnt2w[w]==N) cnt2++;
            if(h==w&&cnt2x==N) cnt2++;
            if(h+w==N-1&&cnt2y==N) cnt2++;
        }
        
        if(cnt1>=u&&cnt2>=v){
            cout<<"DRAW"<<endl;
            return 0;
        }else if(cnt1>=u){
            cout<<"USAGI"<<endl;
            return 0;
        }else if(cnt2>=v){
            cout<<"NEKO"<<endl;
            return 0;
        }
    }
    
    cout<<"DRAW"<<endl;
}




Measured memory_bytes: 18420