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.io.*;
import java.util.*;

public class main
{
	private static InputStream stream;
	private static byte[] buf = new byte[1024];
	private static int curChar;
	private static int numChars;
	private static SpaceCharFilter filter;
	private static PrintWriter pw;
	private static long mod = 1000000000 + 7;
	private static long mod1 = 1000000000 + 9;
	private static int block;
	static LinkedList<Integer>[] l;
	static int[] c;
	static int[] ans;
	static int k;
	static HashMap<Long,Integer> arr;
	static int[] arr1;
	private static void soln()
	{
		int n=nextInt();
		HashMap<Integer,Integer> s=new HashMap<>();
		for(int i=0;i<n;i++){
		    int x=nextInt();
		    if(!s.containsKey(x))
		    	s.put(x, 0);
			s.put(x,s.get(x)+1);
		}
		if(s.size()!=2)
			pw.println("NO");
		else {
			HashSet<Integer> s1=new HashSet<>();
			for(int x:s.keySet()) {
				s1.add(s.get(x));
			}
			if(s1.size()==1) {
				pw.println("YES");
				for(int x:s.keySet()) {
				pw.print(x+" ");
				}
			}else
				pw.println("NO");
		}
		/*int n=nextInt();
		Pair[] arr=new Pair[n];
		int max=0;
		for(int i=0;i<n;i++) {
			int ti=nextInt();
			int di=nextInt();
			int pi=nextInt();
			max=Math.max(max, di);
			arr[i]=new Pair(ti,di,pi);
		}
		int[][] dp=new int[n+1][max+1];
		for(int i=0;i<n;i++) {
			for(int d=arr[i].ti;d<=max;d++) {
				dp[i+1][d]=Math.max(dp[i][d],dp[i][d-arr[i].ti]+arr[i].pi);
			}
		}
		int ans=0;
		for(int d=0;d<=max;d++)
			ans=Math.max(ans, dp[n][d]);
		pw.println(ans);*/
	}
	private static class Pair{
		int ti,di,pi;
		public Pair(int t,int d,int p){
			ti=t;
			pi=p;
			di=d;
		}
	}
	private static void dfs(int cur,int prev) {
		Iterator<Integer> it=l[cur].listIterator();
		//System.out.println(cur);
		int co=c[cur];
		long tmp=((long)co << 20) + (long)(arr1[co]);
		if(arr1[co]-k < 0)
			ans[cur]=-2;
		else {
			ans[cur]=arr.get(tmp-k);
		}
		arr.put(tmp,arr1[co]);
		arr1[co]++;
		while(it.hasNext()) {
			int x=it.next();
			if(x!=prev) {
				dfs(x,cur);
			}
		}
		arr.remove(tmp);
		arr1[co]--;
	}
	private static class Node{
		int val;
		Node left;
		Node right;
		public Node(int v) {
			val=v;
		}
	}
	public static class Segment {
		private int[] tree;
		private int[] base;
		private int size;
		private int n;
		private class node{
			private int a;
			private int b;
			private int c;
			public node(int x,int y,int z){
				a=x;
				b=y;
				c=z;
			}
		}
		public Segment(int n,int[] arr){
			//this.base=arr;
			int x = (int) (Math.ceil(Math.log(n) / Math.log(2)));
	        size = 2 * (int) Math.pow(2, x) - 1;
			tree=new int[size];
			base=arr;
			this.n=n;
			build(0,0,n-1);
		}
		public void build(int id,int l,int r) {
			if(l==r) {
				tree[id]=base[l];
				return;
			}
			int mid=l+((r-l)>>1);
			build((id<<1)+1,l,mid);
			build((id<<1)+2,mid+1,r);
			tree[id]=Math.max(tree[(id<<1)+1],tree[(id<<1)+2]);
		}
		public int query(int l,int r){
			return queryUtil(l,r,0,0,n-1);
		}
		private int queryUtil(int x,int y,int id,int l,int r){
			if(l>y || x>r) 
				return 0;
			if(x <= l && r<=y)
				return tree[id];
			int mid=l+((r-l)>>1);
			return Math.max(queryUtil(x,y,(id<<1)+1,l,mid),queryUtil(x,y,(id<<1)+2,mid+1,r));
		}
		public void update(int x,int colour,int id,int l,int r){
			//System.out.println(l+" "+r+" "+x);
			if(x>r || x<l)
				return;
			if(l==r){
				tree[id]+=colour;
				return;
			}
			int mid=l+(r-l)/2;
			update(x,colour,2*id+1,l,mid);
			update(x,colour,2*id+2,mid+1,r);
			tree[id]=tree[2*id+1]+tree[2*id+2];
		}
	}

	static void multiply(long[][] a, long[][] b, long m)
	{
		int n = a.length;
		long[][] mul = new long[n][n];
		for (int i = 0; i < n; i++)
		{
			for (int j = 0; j < n; j++)
			{
				mul[i][j] = 0;
				for (int k = 0; k < n; k++)
					mul[i][j] = (mul[i][j] + (a[i][k] * b[k][j]) % m) % m;
			}
		}
		for (int i = 0; i < n; i++)
			for (int j = 0; j < n; j++)
				a[i][j] = mul[i][j];
	}
	private static class DSU{
		int[] parent;
		int[] rank;
		int[][] lr;
		public DSU(int n){
			parent=new int[n];
			rank=new int[n];
			lr=new int[n][2];
			//cnt=new int[n];
			for(int i=0;i<n;i++){
				parent[i]=i;
				rank[i]=1;
				lr[i][0]=lr[i][1]=i;
				//cnt[i]=1;
			}
		}
		int find(int i){
	        while(parent[i] !=i){
	        	parent[i]=parent[parent[i]];
	        	i=parent[i];
	        }
	        return i;
	    }
		int Union(int x, int y){
	        int xset = find(x);
	        int yset = find(y);
	        if(xset==yset)
	        	return 0;
	        	parent[yset]=xset;
	        	rank[xset]+=rank[yset];
	        	rank[yset]=0;
	        	lr[xset][1]=lr[yset][1];
	        	lr[yset][0]=lr[xset][0];
	        	//cnt[xset]+=cnt[yset];
	        	//cnt[yset]=0;
	        	return xset;
	    }
	}

	private static long pow(long a, long b, long c)
	{
		if (b == 0)
			return 1;
		long p = pow(a, b / 2, c);
		p = (p * p) % c;
		return (b % 2 == 0) ? p : (a * p) % c;
	}
	private static class Mo implements Comparable<Mo>
	{
		int l;
		int r;
		int i;

		public Mo(int a, int b, int ind)
		{
			l = a;
			r = b;
			i = ind;
		}

		@Override
		public int compareTo(Mo arg0)
		{
			int b1 = this.l / block;
			int b2 = arg0.l / block;
			return (b1 != b2) ? (b1 - b2) : (this.r - arg0.r);
		}
	}

	private static long gcd(long n, long l)
	{
		if (l == 0)
			return n;
		return gcd(l, n % l);
	}
	public static void main(String[] args) throws Exception
	{
		new Thread(null, new Runnable()
		{
			@Override
			public void run()
			{
				/*try { 
					InputReader(new FileInputStream("C:\\Users\\hardik\\Desktop\\B-large-practice.in")); 
				} catch (FileNotFoundException e) { // TODO Auto-generated catch block
					e.printStackTrace(); 
				} */
				InputReader(System.in);
				pw = new PrintWriter(System.out);
				/*try { 
					pw=new PrintWriter(new FileOutputStream("C:\\Users\\hardik\\Desktop\\out.txt")); 
				} catch (FileNotFoundException e) { // TODO Auto-generated catch block
					e.printStackTrace();
				}*/
				soln();
				pw.close();
			}
		}, "1", 1 << 26).start();
	}

	public static void InputReader(InputStream stream1)
	{
		stream = stream1;
	}

	private static boolean isWhitespace(int c)
	{
		return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
	}

	private static boolean isEndOfLine(int c)
	{
		return c == '\n' || c == '\r' || c == -1;
	}

	private static int read()
	{
		if (numChars == -1)
			throw new InputMismatchException();
		if (curChar >= numChars)
		{
			curChar = 0;
			try
			{
				numChars = stream.read(buf);
			} catch (IOException e)
			{
				throw new InputMismatchException();
			}
			if (numChars <= 0)
				return -1;
		}
		return buf[curChar++];
	}

	private static int nextInt()
	{
		int c = read();
		while (isSpaceChar(c))
			c = read();
		int sgn = 1;
		if (c == '-')
		{
			sgn = -1;
			c = read();
		}
		int res = 0;
		do
		{
			if (c < '0' || c > '9')
				throw new InputMismatchException();
			res *= 10;
			res += c - '0';
			c = read();
		} while (!isSpaceChar(c));
		return res * sgn;
	}

	private static long nextLong()
	{
		int c = read();
		while (isSpaceChar(c))
			c = read();
		int sgn = 1;
		if (c == '-')
		{
			sgn = -1;
			c = read();
		}
		long res = 0;
		do
		{
			if (c < '0' || c > '9')
				throw new InputMismatchException();
			res *= 10;
			res += c - '0';
			c = read();
		} while (!isSpaceChar(c));
		return res * sgn;
	}

	private static String nextToken()
	{
		int c = read();
		while (isSpaceChar(c))
			c = read();
		StringBuilder res = new StringBuilder();
		do
		{
			res.appendCodePoint(c);
			c = read();
		} while (!isSpaceChar(c));
		return res.toString();
	}

	private static String nextLine()
	{
		int c = read();
		while (isSpaceChar(c))
			c = read();
		StringBuilder res = new StringBuilder();
		do
		{
			res.appendCodePoint(c);
			c = read();
		} while (!isEndOfLine(c));
		return res.toString();
	}

	private static int[] nextIntArray(int n)
	{
		int[] arr = new int[n];
		for (int i = 0; i < n; i++)
		{
			arr[i] = nextInt();
		}
		return arr;
	}

	private static long[] nextLongArray(int n)
	{
		long[] arr = new long[n];
		for (int i = 0; i < n; i++)
		{
			arr[i] = nextLong();
		}
		return arr;
	}

	private static void pArray(int[] arr)
	{
		for (int i = 0; i < arr.length; i++)
		{
			System.out.print(arr[i] + " ");
		}
		System.out.println();
		return;
	}

	private static void pArray(long[] arr)
	{
		for (int i = 0; i < arr.length; i++)
		{
			System.out.print(arr[i] + " ");
		}
		System.out.println();
		return;
	}

	private static boolean isSpaceChar(int c)
	{
		if (filter != null)
			return filter.isSpaceChar(c);
		return isWhitespace(c);
	}

	private static char nextChar()
	{
		int c = read();
		while (isSpaceChar(c))
			c = read();
		char c1 = (char) c;
		while (!isSpaceChar(c))
			c = read();
		return c1;
	}

	private interface SpaceCharFilter
	{
		public boolean isSpaceChar(int ch);
	}
}