Problem:
Score: 300 points

Problem Statement

Takahashi has decided to hold fastest-finger-fast quiz games. Kizahashi, who is in charge of making the scoreboard, is struggling to write the program that manages the players' scores in a game, which proceeds as follows.

A game is played by N players, numbered 1 to N. At the beginning of a game, each player has K points.

When a player correctly answers a question, each of the other N-1 players receives minus one (-1) point. There is no other factor that affects the players' scores.

At the end of a game, the players with 0 points or lower are eliminated, and the remaining players survive.

In the last game, the players gave a total of Q correct answers, the i-th of which was given by Player A_i.
For Kizahashi, write a program that determines whether each of the N players survived this game.

Constraints

All values in input are integers.

2 \leq N \leq 10^5

1 \leq K \leq 10^9

1 \leq Q \leq 10^5

1 \leq A_i \leq N\ (1 \leq i \leq Q)

Input

Input is given from Standard Input in the following format:

N K Q
A_1
A_2
.
.
.
A_Q

Output

Print N lines. The i-th line should contain Yes if Player i survived the game, and No otherwise.

Sample Input 1

6 3 4
3
1
3
2

Sample Output 1

No
No
Yes
No
No
No

In the beginning, the players' scores are (3, 3, 3, 3, 3, 3).

Player 3 correctly answers a question. The players' scores are now (2, 2, 3, 2, 2, 2).

Player 1 correctly answers a question. The players' scores are now (2, 1, 2, 1, 1, 1).

Player 3 correctly answers a question. The players' scores are now (1, 0, 2, 0, 0, 0).

Player 2 correctly answers a question. The players' scores are now (0, 0, 1, -1, -1, -1).

Players 1, 2, 4, 5 and 6, who have 0 points or lower, are eliminated, and Player 3 survives this game.

Sample Input 2

6 5 4
3
1
3
2

Sample Output 2

Yes
Yes
Yes
Yes
Yes
Yes

Sample Input 3

10 13 15
3
1
4
1
5
9
2
6
5
3
5
8
9
7
9

Sample Output 3

No
No
No
No
Yes
No
No
No
Yes
No

Solution in Rust (1.42.0) (judge verdict: Accepted)

//  ____            _                  _                       _       _
// |  _ \ _   _ ___| |_    ___ _ __   | |_ ___ _ __ ___  _ __ | | __ _| |_ ___
// | |_) | | | / __| __|  / __| '_ \  | __/ _ \ '_ ` _ \| '_ \| |/ _` | __/ _ \
// |  _ <| |_| \__ \ |_  | (__| |_) | | ||  __/ | | | | | |_) | | (_| | ||  __/
// |_| \_\\__,_|___/\__|  \___| .__/___\__\___|_| |_| |_| .__/|_|\__,_|\__\___|
//                            |_| |_____|               |_|

//https://github.com/manta1130/Competitive_Programming_Template_Rust


mod segtree {

///汎用のセグメント木
pub struct SegTreeBasic<T, F> {
    //n: usize,
    v: Vec<T>,
    init: T,
    parent_generator: F,
}

impl<T, F> SegTreeBasic<T, F>
where
    T: PartialOrd + Clone + Copy,
    F: Fn(T, T) -> T,
{
    ///セグメント木を構築する。
    ///
    /// # Examples
    /// ```ignore
    /// let mut segtree = SegTreeBasic::new(100, usize::max_value(), |a, b| std::cmp::min(a, b));
    /// //要素数100のRMQを構築する。
    /// ```
    pub fn new(n: usize, init: T, parent_generator: F) -> SegTreeBasic<T, F> {
        let mut size = 1;
        while size < n {
            size *= 2;
        }
        let v = vec![init; size * 2 - 1];
        SegTreeBasic {
            //n: size,
            v: v,
            init: init,
            parent_generator: parent_generator,
        }
    }

    ///[l,r)の要素をparent_generatorに基づいて計算する。
    pub fn get(&mut self, l: usize, r: usize) -> T {
        let vlen = self.v.len();
        self._get(l, r, 0, 0, (vlen + 1) / 2)
    }

    fn _get(&mut self, l: usize, r: usize, now: usize, a: usize, b: usize) -> T {
        if a >= r || b <= l {
            self.init
        } else if l <= a && b <= r {
            self.v[now]
        } else {
            let bufa = self._get(l, r, now * 2 + 1, a, (a + b) / 2);
            let bufb = self._get(l, r, now * 2 + 2, (a + b) / 2, b);
            let cond = &self.parent_generator;
            cond(bufa, bufb)
        }
    }

    ///任意の要素を書き換える。
    pub fn update(&mut self, index: usize, value: T) {
        let offset = (self.v.len() + 1) / 2 - 1;
        self.v[offset + index] = value;
        let mut parent = index + offset;
        loop {
            parent = (parent - 1) / 2;
            let cond = &self.parent_generator;
            self.v[parent] = cond(self.v[parent * 2 + 1], self.v[parent * 2 + 2]);
            if parent == 0 {
                break;
            }
        }
    }
}

///汎用の遅延セグメント木
pub struct SegTreeLazy<T, F, G, H> {
    //n: usize,
    v: Vec<T>,
    lazy: Vec<T>,
    lazy_flag: Vec<bool>,
    init: T,
    lazy_init: T,
    lazy_convert: F,
    lazy_propagation: G,
    parent_generator: H,
}

impl<T, F, G, H> SegTreeLazy<T, F, G, H>
where
    T: PartialOrd + Clone + Copy,
    F: Fn(T, T) -> T,
    G: Fn(T, T) -> T,
    H: Fn(T, T) -> T,
{
    ///遅延セグメント木を構築する。
    ///
    /// # Examples
    /// ```ignore
    ///　let mut segtree = SegTreeLazy::new(100, 0, 0, |a, b| a + b, |a, b| a + b, |a, b| a + b / 2);
    /// //要素数100の区間加算・区間取得のセグ木を構築する。
    /// ```
    pub fn new(
        n: usize,
        init: T,
        lazy_init: T,
        parent_generator: H,
        lazy_convert: F,
        lazy_propagation: G,
    ) -> SegTreeLazy<T, F, G, H> {
        let mut size = 1;
        while size < n {
            size *= 2;
        }
        let v = vec![init; size * 2 - 1];
        let lazy = vec![lazy_init; size * 2 - 1];
        let lazy_flag = vec![false; size * 2 - 1];
        SegTreeLazy {
            v: v,
            lazy: lazy,
            init: init,
            lazy_init: lazy_init,
            lazy_flag: lazy_flag,
            lazy_convert: lazy_convert,
            lazy_propagation: lazy_propagation,
            parent_generator: parent_generator,
        }
    }

    ///[l,r)の要素をparent_generatorに基づいて計算する。
    pub fn get(&mut self, l: usize, r: usize) -> T {
        let vlen = self.v.len();
        self._get(l, r, 0, 0, (vlen + 1) / 2)
    }

    fn _eval(&mut self, now: usize) {
        if now >= self.lazy_flag.len() {
            return;
        }

        if now * 2 + 2 < self.lazy.len() && self.lazy[now] != self.lazy_init {
            let propagation = &self.lazy_propagation;
            self.lazy[now * 2 + 1] = propagation(self.lazy[now * 2 + 1], self.lazy[now]);
            self.lazy[now * 2 + 2] = propagation(self.lazy[now * 2 + 2], self.lazy[now]);
        }
        if self.lazy[now] != self.lazy_init {
            let convert = &self.lazy_convert;
            self.v[now] = convert(self.v[now], self.lazy[now]);
        }
        self.lazy[now] = self.lazy_init;
        if self.lazy_flag[now] {
            self._eval(now * 2 + 1);
            self._eval(now * 2 + 2);
            let generator = &self.parent_generator;
            if now * 2 + 2 < self.v.len() {
                self.v[now] = generator(self.v[now * 2 + 1], self.v[now * 2 + 2]);
            }
        }
        self.lazy_flag[now] = false;
    }

    fn _get(&mut self, l: usize, r: usize, now: usize, a: usize, b: usize) -> T {
        self._eval(now);
        if a >= r || b <= l {
            self.init
        } else if l <= a && b <= r {
            self.v[now]
        } else {
            let bufa = self._get(l, r, now * 2 + 1, a, (a + b) / 2);
            let bufb = self._get(l, r, now * 2 + 2, (a + b) / 2, b);
            let cond = &self.parent_generator;
            cond(bufa, bufb)
        }
    }

    ///任意の要素を書き換える。
    pub fn update(&mut self, l: usize, r: usize, v: T) {
        let vlen = self.v.len();
        self._update(l, r, 0, 0, (vlen + 1) / 2, v);
    }

    fn _update(&mut self, l: usize, r: usize, now: usize, a: usize, b: usize, v: T) {
        if now < self.v.len() {
            self._eval(now);
        }
        if l <= a && b <= r {
            let propagation = &self.lazy_propagation;
            self.lazy[now] = propagation(self.lazy[now], v);
            self.lazy_flag[now] = true;
        } else if !(a >= r || b <= l) {
            let v_next;
            {
                let propagation = &self.lazy_propagation;
                v_next = propagation(self.lazy_init, v);
            }
            self._update(l, r, now * 2 + 1, a, (a + b) / 2, v_next);
            self._update(l, r, now * 2 + 2, (a + b) / 2, b, v_next);
            self.lazy_flag[now] = true;
        }
    }
}
}

#[allow(unused_imports)]
use proconio::{
    fastout, input,
    marker::{Bytes, Chars, Isize1, Usize1},
};

use segtree::*;

const num: usize = 131072;

#[fastout]
fn main() {
    input! {
        n:usize,
        k:isize,
        q:usize
    }
    let mut segtree = SegTreeLazy::new(num, 0, 0, |a, b| a + b, |a, b| a + b, |a, b| a + b / 2);
    segtree.update(0, n, 2 * num as isize * k);

    for _ in 0..q {
        input! {
            a:Usize1,
        }
        segtree.update(0, a, -1 * num as isize * 2);
        segtree.update(a + 1, n, -1 * num as isize * 2);
    }

    for i in 0..n {
        //dbg!(segtree.get(i, i + 1));
        if segtree.get(i, i + 1) <= 0 {
            println!("No");
        } else {
            println!("Yes");
        }
    }
}