#include <bits/stdc++.h>
using namespace std;
const int MAXN = 2e5+5;


int t, n, k;
int a[MAXN];

void solve(){
    cin >> t >> n >> k;
    if(n > 10000){
        exit(5);
    }
    bool flip = (k<0);
    for(int i = 1; i <= n; ++i){
        cin >> a[i];
    }
    sort(a+1,a+n+1, [&](int x, int y){
            return (x < y) != flip;
        });
    //for(int i = 1; i <= n; ++i) cout << a[i] << ' '; cout << '\n';
    for(int bg = 1; bg <= n; ++bg){
        int r = (a[bg] >= 0 ? 1 : -1);
        for(int i = bg%n+1; i != bg; i = i%n+1){
            //cout << i << ' ' << r << ' ' << a[i] << '\n';
            r += (a[i] >= r ? 1 : -1);
        }
        //cout << r << '\n';
        if(r == k){
            cout << "DA\n";
            if(t){
                cout << a[bg] << ' ';
                for(int i = bg+1; i != bg; i = i%n+1) cout << a[i] << ' ';
                cout << '\n';
            }
            return;
        }
    }
    cout << "NE\n";
}

int32_t main(){
    ios_base::sync_with_stdio(0);cin.tie(0);
    int qqq=1;
    //cin>>qqq;
    while(qqq--) solve();
}