Problem: Define the simple skewness of a collection of numbers to be the collection's mean minus its median. You are given a list of n (not necessarily distinct) integers. Find the non-empty subset (with repetition) with the maximum simple skewness.

The mean of a collection is the average of its elements. The median of a collection is its middle element when all of its elements are sorted, or the average of its two middle elements if it has even size.

Input

The first line of the input contains a single integer n (1 ≤ n ≤ 200 000) — the number of elements in the list.

The second line contains n integers xi (0 ≤ xi ≤ 1 000 000) — the ith element of the list.

Output

In the first line, print a single integer k — the size of the subset.

In the second line, print k integers — the elements of the subset in any order.

If there are multiple optimal subsets, print any.

Examples

Input

4
1 2 3 12


Output

3
1 2 12 


Input

4
1 1 2 2


Output

3
1 1 2 


Input

2
1 2


Output

2
1 2

Note

In the first case, the optimal subset is <image>, which has mean 5, median 2, and simple skewness of 5 - 2 = 3.

In the second case, the optimal subset is <image>. Note that repetition is allowed.

In the last case, any subset has the same median and mean, so all have simple skewness of 0.

Solution (in JAVA):

Solution:
import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.util.Arrays;
import java.util.StringTokenizer;

public class P626E {

	public static int n;
	public static long[] a;
	public static long[] b;

	public static long diff(int i, int l) {
		return (b[i - l] - b[i + 1] + b[n - l]) - (2 * l + 1) * a[i];
	}

	public static void main(String[] args) throws Exception {
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
//		BufferedReader br = new BufferedReader(new FileReader("input.txt"));
		n = Integer.parseInt(br.readLine());
		a = new long[n];
		StringTokenizer tk = new StringTokenizer(br.readLine());
		for (int i = 0; i < n; i++) {
			a[i] = Long.parseLong(tk.nextToken());
		}

		Arrays.sort(a);
		b = new long[n + 1];
		b[n] = 0L;
		for (int i = n - 1; i >= 0; i--) {
			b[i] = b[i + 1] + a[i];
//			System.err.println(a[i]);
		}

		long maxd = 0L;
		int maxi = 0;
		int maxl = 0;
		for (int i = 1; i < n - 1; i++) {
			int l = Math.min(i, n - 1 - i);
			int x = 1;
			int y = l;
			while (y - x > 1) {
				int z = (x + y) / 2;
				if (diff(i, z) * (2 * (z - 1) + 1) > diff(i, z - 1) * (2 * z + 1)) {
					x = z;
				} else {
					y = z - 1;
				}
			}
			if (diff(i, y) * (2 * (y - 1) + 1) > diff(i, y - 1) * (2 * y + 1)) {
				l = y;
			}else {
				l = x;
			}
			long d = diff(i, l);
			if (maxd * (2 * l + 1) < d * (2 * maxl + 1)) {
				maxd = d;
				maxi = i;
				maxl = l;
			}
		}

		System.out.println(2 * maxl + 1);
		for (int i = maxi - maxl; i <= maxi; i++) {
			System.out.print(a[i] + " ");
		}
		for (int i = n - maxl; i < n; i++) {
			System.out.print(a[i] + " ");
		}
//		System.out.println("\n" + maxd);
	}

}