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 CPP):

Solution:
#include <bits/stdc++.h>
using namespace std;
int n;
int a[200005];
long long sm[200005];
long long f(int i, int j) {
  if (j > i) return -1;
  if (n - 1 - j < i) return -1;
  long long l = sm[i];
  if (i - j > 0) l -= sm[i - j - 1];
  long long r = sm[n - 1];
  r -= sm[n - 1 - j];
  return l + r;
}
int ts(int i) {
  int lo = 0;
  int hi = min(i, n - i - 1);
  int m1, m2;
  while (lo < hi) {
    int len = (hi - lo) / 3;
    m1 = lo + len;
    m2 = lo + max(1, 2 * len);
    long long f1 = f(i, m1);
    long long f2 = f(i, m2);
    if (f1 * (2 * m2 + 1) > f2 * (2 * m1 + 1))
      hi = m2 - 1;
    else
      lo = m1 + 1;
  }
  return lo;
}
int main() {
  scanf("%d", &n);
  for (int i = 0; i < n; i++) scanf("%d", a + i);
  sort(a, a + n);
  for (int i = 0; i < n; i++) {
    sm[i] = a[i];
    if (i) sm[i] += sm[i - 1];
  }
  int bi, bj;
  bi = 0;
  bj = 0;
  long long num = 0;
  for (int i = 0; i < n; i++) {
    int r = ts(i);
    long long n2 = f(i, r) - a[i] * 1ll * (2 * r + 1);
    if (num * (2 * r + 1) < n2 * (2 * bj + 1)) {
      bi = i;
      bj = r;
      num = n2;
    }
  }
  printf("%d\n", 2 * bj + 1);
  for (int i = bi - bj; i <= bi; i++) printf("%d ", a[i]);
  for (int i = n - bj; i < n; i++) printf("%d ", a[i]);
}