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:
//package kz.bsbnb.usci.cli.app;

import java.io.*;
import java.util.Arrays;
import java.util.StringTokenizer;

/**
 * Created by Bauyrzhan.Makhambeto on 15/02/2016.
 */
public class Solver {
  long f(int l,int r,long[] d){
    if(l> r)
      return 0;
    long ret = d[r];
    if(l > 0) ret-=d[l-1];
    return ret;
  }
  public void run(InputReader in, PrintWriter out){
    int a[] = new int[200004];
    int n = in.nextInt();
    for(int i=0;i<n;i++)
      a[i] = in.nextInt();

    Arrays.sort(a,0,n);

    long d[] = new long[n];
    d[0] = a[0];
    for(int i=1;i<n;i++)
      d[i] = d[i-1] + a[i];

    int l1 = 0,r1 = 0,l2=0,r2=0;
    long bestA = 0;
    long bestQ = 1;

    //odd
    for (int i=0;i<n;i++) {
      int l = 0, r = Math.min(i, n-i-1);
      while(r - l > 2 ) {
        int m1 = l + (r-l) / 3;
        int m2 = r - (r-l) / 3;

        long v1 = (f(i-m1,i, d) + f(n-m1,n-1, d));
        long q1 = 2 * m1 + 1;
        long v2 = f(i-m2,i, d) + f(n-m2,n-1, d);
        long q2 = 2 * m2 + 1;

        if(v1 * q2> v2 * q1) {
          r = m2;
        }
        else {
          l = m1;
        }
      }

      for(int m = l;m<=r;m++) {
        long v = (f(i-m,i, d) + f(n-m,n-1, d));
        long q = 2 * m + 1;

        if(bestA * q < (v - q * a[i]) * bestQ) {
          //la = v - a[i];
          l1 = i - m;
          r1 = i;
          l2 = n - m;
          r2 = n - 1;
          bestQ = 2 * m + 1;
          bestA = v - bestQ * a[i];
        }
      }
    }

    if(bestA <= 0) {
      System.out.println("1\n" + a[0]);
      return;
    }

    out.println(r1 - l1 + 1 + r2 - l2 + 1);
    for(int i=l1;i<=r1;i++)
      out.print(a[i] + " ");
    for(int i=l2;i<=r2;i++)
      out.print(a[i] + " ");
  }

  public static void main(String [] args){
    InputStream inputStream = System.in;
    OutputStream outputStream = System.out;
    InputReader in = new InputReader(inputStream);
    PrintWriter out = new PrintWriter(outputStream);
    Solver solver = new Solver();
    solver.run(in, out);
    out.close();
  }

  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());
    }

  }
}