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.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.io.OutputStream;
import java.io.PrintWriter;
import java.util.Arrays;
import java.util.StringTokenizer;

public class Main {
	public static void main(String args[]) {
		InputStream intputStream = System.in;
		OutputStream outputStream = System.out;
		InputReader in = new InputReader(intputStream);
		PrintWriter out = new PrintWriter(outputStream);
		TaskE solver = new TaskE();
		solver.solve(in, out);
		out.close();
	}

	static class TaskE {
		public void solve(InputReader in, PrintWriter out) {
			int n = in.nextInt();
			int[] x = new int[n + 1];
			for (int i = 1; i <= n; ++i) {
				x[i] = in.nextInt();
			}
			Arrays.sort(x);
			long[] sum = new long[n + 1];
			for (int i = 1; i <= n; ++i) {
				sum[i] = sum[i - 1] + x[i];
			}
			int ans1 = 1;
			int ans2 = 0;
			for (int median = 2; median < n; ++median) {
				int l = 1, r = Math.min(median - 1, n - median), res = 0;
				while (l <= r) {
					int mid = (l + r) / 2;
					long p1 = sum[median] - sum[median - mid] + sum[n] - sum[n - mid + 1];
					long p2 = x[median - mid] + x[n - mid + 1];
					if (p1 * 2 <= p2 * (2 * mid - 1)) {
						res = mid;
						l = mid + 1;
					} else {
						r = mid - 1;
					}
				}
				if ((sum[median] - sum[median - res - 1] + sum[n] - sum[n - res]) * (2 * ans2 + 1) - (long)x[median] * (2 * res + 1) * (2 * ans2 + 1) >
					(sum[ans1] - sum[ans1 - ans2 - 1] + sum[n] - sum[n - ans2]) * (2 * res + 1) - (long)x[ans1] * (2 * res + 1) * (2 * ans2 + 1)) {
					ans1 = median;
					ans2 = res;
				}
			}
			out.println(2 * ans2 + 1);
			for (int i = ans1 - ans2; i <= ans1; ++i) {
				out.print(x[i] + " ");
			}
			for (int i = n - ans2 + 1; i <= n; ++i) {
				out.print(x[i] + " ");
			}
		}
	}
	
	static class InputReader {
        public BufferedReader reader;
        public StringTokenizer tokenizer;

        public InputReader(InputStream stream) {
            reader = new BufferedReader(new InputStreamReader(stream), 32768);
            tokenizer = null;
        }

        public String next() {
            while (tokenizer == null || !tokenizer.hasMoreTokens()) {
                try {
                    tokenizer = new StringTokenizer(reader.readLine());
                } catch (IOException e) {
                    throw new RuntimeException(e);
                }
            }
            return tokenizer.nextToken();
        }

        public int nextInt() {
            return Integer.parseInt(next());
        }
    }
}