Problem: Petya and Vasya decided to play a game. They have n cards (n is an even number). A single integer is written on each card.

Before the game Petya will choose an integer and after that Vasya will choose another integer (different from the number that Petya chose). During the game each player takes all the cards with number he chose. For example, if Petya chose number 5 before the game he will take all cards on which 5 is written and if Vasya chose number 10 before the game he will take all cards on which 10 is written.

The game is considered fair if Petya and Vasya can take all n cards, and the number of cards each player gets is the same.

Determine whether Petya and Vasya can choose integer numbers before the game so that the game is fair. 

Input

The first line contains a single integer n (2 ≤ n ≤ 100) — number of cards. It is guaranteed that n is an even number.

The following n lines contain a sequence of integers a1, a2, ..., an (one integer per line, 1 ≤ ai ≤ 100) — numbers written on the n cards.

Output

If it is impossible for Petya and Vasya to choose numbers in such a way that the game will be fair, print "NO" (without quotes) in the first line. In this case you should not print anything more.

In the other case print "YES" (without quotes) in the first line. In the second line print two distinct integers — number that Petya should choose and the number that Vasya should choose to make the game fair. If there are several solutions, print any of them.

Examples

Input

4
11
27
27
11


Output

YES
11 27


Input

2
6
6


Output

NO


Input

6
10
20
30
20
10
20


Output

NO


Input

6
1
1
2
2
3
3


Output

NO

Note

In the first example the game will be fair if, for example, Petya chooses number 11, and Vasya chooses number 27. Then the will take all cards — Petya will take cards 1 and 4, and Vasya will take cards 2 and 3. Thus, each of them will take exactly two cards.

In the second example fair game is impossible because the numbers written on the cards are equal, but the numbers that Petya and Vasya should choose should be distinct.

In the third example it is impossible to take all cards. Petya and Vasya can take at most five cards — for example, Petya can choose number 10 and Vasya can choose number 20. But for the game to be fair it is necessary to take 6 cards.

Solution (in JAVA):

Solution:
import java.util.*;

public class CF102 {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n=sc.nextInt();
       int[] ar=new int[n];
        Set<Integer> set=new HashSet<>();
        Map<Integer,Integer> map=new HashMap<>();

       for(int i=0;i<n;i++){
           ar[i]=sc.nextInt();
           set.add(ar[i]);
           map.putIfAbsent(ar[i], 0);
           map.put(ar[i],map.get(ar[i])+1);
       }
       if(set.size()!=2){
           System.out.println("NO");
       }else {
           boolean check=true;
           for(Integer integer:set){
               if(map.get(integer)!=n/2){
                   check=false;
                   break;
               }
           }
           if(check){
               System.out.println("YES");
               for(Integer integer:set){
                   System.out.print(integer+" ");
               }
               System.out.println();
           }else {
               System.out.println("NO");
           }
       }


    }


    public static int frog(int n, int[] dp, int[] ar, int k) {
        if (n == 1) {
            dp[1] = 0;
            return dp[1];
        }
        if (n == 2) {
            dp[2] = Math.abs(ar[n] - ar[n - 1]);
            return dp[2];
        }
        if (dp[n] != -1) {
            return dp[n];
        }
        int min = Integer.MAX_VALUE;
        for (int i = 1; i <= k; i++) {
            if ((n - i) >= 1) {
                min = Math.min(min, frog((n - i), dp, ar, k) + Math.abs(ar[n] - ar[n - i]));
            } else {
                break;
            }
        }
        dp[n] = min;
        return dp[n];
    }

    public static boolean funky(long mid, long n, long orig) {
        long vas = 0;
        while (n > 0) {
            long y = Math.min(mid, n);
            n -= y;
            vas = vas + y;
            n -= n / 10;
        }
        return 2 * vas >= orig;
    }


    public static long sweetness(long a) {
        long c = 0;
        for (long i = 1; i <= a; i++) {
            if (gcd(i, a) == 1) {
                c++;
            }
        }
        return c;
    }

    public static long power(long a, long b, long c) {
        long ans = 1;
        while (b != 0) {
            if (b % 2 == 1) {
                ans = ans * a;
                ans %= c;
            }
            a = a * a;
            a %= c;
            b /= 2;
        }
        return ans;
    }

    public static long power1(long a, long b, long c) {
        long ans = 1;
        while (b != 0) {
            if (b % 2 == 1) {
                ans = multiply(ans, a, c);
            }
            a = multiply(a, a, c);
            b /= 2;

        }
        return ans;

    }

    public static long multiply(long a, long b, long c) {
        long res = 0;
        a %= c;
        while (b > 0) {
            if (b % 2 == 1) {
                res = (res + a) % c;
            }
            a = (a + a) % c;
            b /= 2;
        }

        return res % c;

    }

    public static long totient(long n) {
        long result = n;
        for (long i = 2; i * i <= n; i++) {
            if (n % i == 0) {
                //sum=sum+2*i;
                while (n % i == 0) {
                    n /= i;
                    // sum=sum+n;
                }
                result -= result / i;

            }
        }
        if (n > 1) {
            result -= result / n;

        }
        return result;
    }


    public static long gcd(long a, long b) {
        if (b == 0) {
            return a;
        } else {
            return gcd(b, a % b);
        }
    }

    public static boolean[] primes(int n) {
        boolean[] p = new boolean[n + 1];
        p[0] = false;
        p[1] = false;
        for (int i = 2; i <= n; i++) {
            p[i] = true;
        }

        for (int i = 2; i * i <= n; i++) {
            if (p[i]) {
                for (int j = i * i; j <= n; j += i) {
                    p[j] = false;
                }
            }

        }
        return p;
    }

    public int minimumLength(String s) {
        String s1 = "";
        for (int i = 0; i < s.length() - 1; i++) {
            char ch = s.charAt(i);
            char ch1 = s.charAt(i + 1);
            if (ch != ch1) {
                s1 = s1 + ch;

            }


        }
        s1 = s1 + s.charAt(s.length() - 1);
        String[] ar = s1.split("");
        for (int i = 0; i < s1.length() - 1; i++) {
            if (i <= s1.length() - 1 - i) {
                char ch1 = ar[i].charAt(0);
                char ch2 = ar[s1.length() - 1 - i].charAt(0);
                if (ch1 != ch2) {
                    break;
                } else {
                    ar[i] = "";
                    ar[s1.length() - 1 - i] = "";
                }
            } else {
                break;
            }

        }

        String s2 = "";
        for (String s3 : ar) {
            s2 = s2 + s3;
        }

        return s2.length();


    }

    public static long[] totientfrom1ton(long n) {
        long[] totient = new long[(int) (n + 1)];
        totient[0] = 0;
        totient[1] = 1;
        for (int i = 2; i <= n; i++) {
            totient[i] = i;
        }
        for (int i = 2; i <= n; i++) {
            if (totient[i] == i) {
                totient[i] -= 1;
                for (int j = 2 * i; j <= n; j += i) {
                    totient[j] -= totient[j] / i;
                }
            }
        }
        return totient;

    }

    static long[] LcmSum(int n, long[] phi) {
        //ETF();
        long[] ans = new long[n + 1];

        for (int i = 1; i <= n; i++) {

            // Summation of d * ETF(d) where
            // d belongs to set of divisors of n
            for (int j = i; j <= n; j += i) {
                ans[j] += (i * phi[i]);
            }
        }

        for (int i = 1; i <= n; i++) {
            ans[i] = ((ans[i] + 1) * i) / 2;
        }

        /*int answer = ans[m];
        answer = (answer + 1) * m;
        answer = answer / 2;*/
        return ans;
    }

    static int hackerlandRadioTransmitters(int[] x, int k) {
        Arrays.sort(x);
        int c = 0;
        int lol = 0;
        process:
        while (lol <= (x.length - 1)) {


            int initial = x[lol];
            int nextno = initial + 2 * k;
            int low = lol + 1;
            int high = x.length - 1;
            int ans = -1;
            while (low <= high) {
                int mid = low + (high - low) / 2;
                if (x[mid] <= nextno) {
                    ans = mid;
                    low = mid + 1;
                } else {
                    high = mid - 1;
                }
            }
            if (ans != -1) {
                c++;
            }
            System.out.println(ans + " " + lol);
            lol = ans + 1;
        }
        return c;


    }
}