Problem: Vasya has a multiset s consisting of n integer numbers. Vasya calls some number x nice if it appears in the multiset exactly once. For example, multiset \{1, 1, 2, 3, 3, 3, 4\} contains nice numbers 2 and 4.

Vasya wants to split multiset s into two multisets a and b (one of which may be empty) in such a way that the quantity of nice numbers in multiset a would be the same as the quantity of nice numbers in multiset b (the quantity of numbers to appear exactly once in multiset a and the quantity of numbers to appear exactly once in multiset b).

Input

The first line contains a single integer n~(2 ≤ n ≤ 100).

The second line contains n integers s_1, s_2, ... s_n~(1 ≤ s_i ≤ 100) — the multiset s.

Output

If there exists no split of s to satisfy the given requirements, then print "NO" in the first line.

Otherwise print "YES" in the first line.

The second line should contain a string, consisting of n characters. i-th character should be equal to 'A' if the i-th element of multiset s goes to multiset a and 'B' if if the i-th element of multiset s goes to multiset b. Elements are numbered from 1 to n in the order they are given in the input.

If there exist multiple solutions, then print any of them.

Examples

Input

4
3 5 7 1


Output

YES
BABA


Input

3
3 5 1


Output

NO

Solution (in JAVA):

Solution:
import java.io.IOException;
import java.io.OutputStreamWriter;
import java.io.PrintWriter;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Collections;
import java.util.Comparator;
import java.util.List;
import java.util.Stack;

public class Main {

    PrintWriter out = new PrintWriter(new OutputStreamWriter(System.out));
    private static boolean debug = false;

    private String nextString() {
        StringBuilder sb = new StringBuilder();
        try {
            char c = (char) System.in.read();
            while (c == ' ' || c == '\n' || c == '\t') {
                c = (char) System.in.read();
            }
            do {
                sb.append(c);
                c = (char) System.in.read();
            } while (c != ' ' && c != '\n' && c != '\t');
        } catch (IOException e) {
            e.printStackTrace();
        }
        return sb.toString();
    }

    private int nextInt() {
        int r = 0;
        boolean f = false;
        try {
            int c = System.in.read();
            while (c < '0' || c > '9') {
                if (c == '-') {
                    f = true;
                }
                c = System.in.read();
            }
            while (c >= '0' && c <= '9') {
                r = r * 10 + c - '0';
                c = System.in.read();
            }
        } catch (IOException e) {
            e.printStackTrace();
        }
        if (f) {
            r *= -1;
        }
        return r;
    }

    private long nextLong() {
        long r = 0;
        boolean f = false;
        try {
            int c = System.in.read();
            while (c < '0' || c > '9') {
                if (c == '-') {
                    f = true;
                }
                c = System.in.read();
            }
            while (c >= '0' && c <= '9') {
                r = r * 10 + c - '0';
                c = System.in.read();
            }
        } catch (IOException e) {
            e.printStackTrace();
        }
        if (f) {
            r *= -1;
        }
        return r;
    }

    private void println(String s) {
        out.write(s);
        out.write('\n');
        out.flush();
    }

    private void print(String s) {
        out.write(s);
        out.flush();
    }

    private void println(long s) {
        println(String.valueOf(s));
    }

    public class AVL<T> {

        private Node<T> root = null;
        private final Comparator<T> comparator;

        public AVL(Comparator<T> comparator) {
            this.comparator = comparator;
        }

        public void insert(T v) {
            if (root == null) {
                root = new Node<>(v, this.comparator);
            } else {
                root = root.insert(v);
            }
        }

        public int gt(T v) {
            return root == null ? 0 : root.gt(v);
        }

        public class Node<T> {
            T v;
            Comparator<T> comparator;
            int size = 1;
            int dep = 1;
            Node<T> lc = null;
            Node<T> rc = null;

            public Node(T v, Comparator<T> comparator) {
                this.v = v;
                this.comparator = comparator;
            }

            private int getDep(Node node) {
                return node == null ? 0 : node.dep;
            }

            private int getSize(Node node) {
                return node == null ? 0 : node.size;
            }

            public Node<T> insert(T v) {
                Node<T> rt = this;
                if (comparator.compare(v, this.v) >= 0) {
                    if (this.rc == null) {
                        this.rc = new Node<>(v, this.comparator);
                    } else {
                        this.rc = this.rc.insert(v);
                    }
                } else {
                    if (this.lc == null) {
                        this.lc = new Node<>(v, this.comparator);
                    } else {
                        this.lc = this.lc.insert(v);
                    }
                }
                if (getDep(this.lc) > getDep(this.rc) + 1) {
                    Node<T> lc = this.lc;
                    this.lc = lc.rc;
                    lc.rc = this;
                    this.update();
                    lc.update();
                    rt = lc;
                } else if (getDep(this.rc) > getDep(this.lc) + 1) {
                    Node<T> rc = this.rc;
                    this.rc = rc.lc;
                    rc.lc = this;
                    this.update();
                    rc.update();
                    rt = rc;
                } else {
                    this.update();
                }
                return rt;
            }

            private void update() {
                this.dep = Math.max(getDep(this.rc), getDep(this.lc)) + 1;
                this.size = getSize(this.rc) + getSize(this.lc) + 1;
            }

            public int gt(T v) {
                if (comparator.compare(v, this.v) >= 0) {
                    return this.rc == null ? 0 : this.rc.gt(v);
                } else {
                    return getSize(this.rc) + 1 + (this.lc == null ? 0 : this.lc.gt(v));
                }
            }
        }

    }

    public static void main(String[] args) {
        new Main().resolve();
    }

    private void resolve() {
        int n = nextInt();
        int[] d = new int[n];
        int[] ct = new int[101];
        Arrays.fill(ct, 0);
        int cnt = 0;
        int gt = 0;
        for (int i = 0; i < n; i++) {
            d[i] = nextInt();
            ct[d[i]]++;
            if (ct[d[i]] == 1) {
                cnt++;
            } else if (ct[d[i]] == 2) {
                cnt--;
            } else if (ct[d[i]] == 3) {
                gt++;
            }
        }
        if (cnt % 2 == 1 && gt == 0) {
            println("NO");
        } else {
            println("YES");
            boolean l = true;
            int sp = -1;
            String re = "";
            for (int i = 0; i < n; i++) {
                if (ct[d[i]] == 1) {
                    print(l ? "A" : "B");
                    l = !l;
                } else if (cnt % 2 == 1 && ct[d[i]] >= 3) {
                    print(l ? "A" : "B");
                    sp = d[i];
                    re = l ? "B" : "A";
                    l = !l;
                    cnt--;
                } else if (sp == d[i]) {
                    print(re);
                } else {
                    print("A");
                }
            }
            print("\n");
        }
    }
}