Simon has an array a1, a2, ..., an, consisting of n positive integers. Today Simon asked you to find a pair of integers l, r (1 ≤ l ≤ r ≤ n), such that the following conditions hold:

  1. there is integer j (l ≤ j ≤ r), such that all integers al, al + 1, ..., ar are divisible by aj; 
  2. value r - l takes the maximum value among all pairs for which condition 1 is true; 



Help Simon, find the required pair of numbers (l, r). If there are multiple required pairs find all of them.

Input

The first line contains integer n (1 ≤ n ≤ 3·105).

The second line contains n space-separated integers a1, a2, ..., an (1 ≤ ai ≤ 106).

Output

Print two integers in the first line — the number of required pairs and the maximum value of r - l. On the following line print all l values from optimal pairs in increasing order.

Examples

Input

5
4 6 9 3 6


Output

1 3
2 


Input

5
1 3 5 7 9


Output

1 4
1 


Input

5
2 3 5 7 11


Output

5 0
1 2 3 4 5 

Note

In the first sample the pair of numbers is right, as numbers 6, 9, 3 are divisible by 3.

In the second sample all numbers are divisible by number 1.

In the third sample all numbers are prime, so conditions 1 and 2 are true only for pairs of numbers (1, 1), (2, 2), (3, 3), (4, 4), (5, 5).
import java.io.OutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.OutputStream;
import java.io.PrintWriter;
import java.io.BufferedWriter;
import java.util.InputMismatchException;
import java.io.IOException;
import java.util.ArrayList;
import java.util.List;
import java.io.Writer;
import java.io.OutputStreamWriter;
import java.io.InputStream;

/**
 * Built using CHelper plug-in
 * Actual solution is at the top
 *
 * @author prakharjain
 */
public class Main {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        InputReader in = new InputReader(inputStream);
        OutputWriter out = new OutputWriter(outputStream);
        DPairOfNumbers solver = new DPairOfNumbers();
        solver.solve(1, in, out);
        out.close();
    }

    static class DPairOfNumbers {
        int[][] stmin;
        int[][] stgcd;
        int[] a;
        int n;
        int log;

        public void solve(int testNumber, InputReader in, OutputWriter out) {

            n = in.nextInt();

            a = in.nextIntArray(n);

            log = 0;

            while ((1 << log) <= n) {
                log++;
            }

            stmin = new int[n][log];
            stgcd = new int[n][log];

            for (int i = n - 1; i >= 0; i--) {
                stmin[i][0] = stgcd[i][0] = a[i];
                for (int j = 1; j < log; j++) {
                    stmin[i][j] =
                            Math.min(stmin[i][j - 1],
                                    stmin[Math.min(i + (1 << (j - 1)), n - 1)][j - 1]);
                    stgcd[i][j] =
                            gcd(stgcd[i][j - 1],
                                    stgcd[Math.min(i + (1 << (j - 1)), n - 1)][j - 1]);
                }
            }

            int lo = 1;
            int hi = n;

            int ans = lo;
            while (lo <= hi) {
                int mid = (lo + hi) / 2;

                boolean poss = solve(mid);

                if (poss) {
                    ans = mid;
                    lo = mid + 1;
                } else {
                    hi = mid - 1;
                }
            }

            int cl = 0;

            while ((1 << cl) <= ans) {
                cl++;
            }

            cl--;

            List<Integer> l = new ArrayList<>();
            for (int i = 0; i < n - ans + 1; i++) {
                int j = i + ans - 1;

                int gcd = querygcd(i, j, cl);
                int min = querymin(i, j, cl);

                if (gcd == min) {
                    l.add(i + 1);
                }
            }

            out.println(l.size() + " " + (ans - 1));
            for (int i = 0; i < l.size(); i++) {
                out.print(l.get(i) + " ");
            }
        }

        int querygcd(int l, int r, int cl) {
            return gcd(stgcd[l][cl], stgcd[r - (1 << cl) + 1][cl]);
        }

        int querymin(int l, int r, int cl) {
            return Math.min(stmin[l][cl], stmin[r - (1 << cl) + 1][cl]);
        }

        boolean solve(int size) {
            int cl = 0;

            while ((1 << cl) <= size) {
                cl++;
            }

            cl--;

            for (int i = 0; i < n - size + 1; i++) {
                int j = i + size - 1;

                int gcd = querygcd(i, j, cl);
                int min = querymin(i, j, cl);

                if (gcd == min) {
                    return true;
                }
            }

            return false;
        }

        int gcd(int a, int b) {
            if (b == 0)
                return a;
            else
                return gcd(b, a % b);
        }

    }

    static class OutputWriter {
        private final PrintWriter writer;

        public OutputWriter(OutputStream outputStream) {
            writer = new PrintWriter(new BufferedWriter(new OutputStreamWriter(outputStream)));
        }

        public OutputWriter(Writer writer) {
            this.writer = new PrintWriter(writer);
        }

        public void print(Object... objects) {
            for (int i = 0; i < objects.length; i++) {
                if (i != 0) {
                    writer.print(' ');
                }
                writer.print(objects[i]);
            }
        }

        public void println(Object... objects) {
            print(objects);
            writer.println();
        }

        public void close() {
            writer.close();
        }

    }

    static class InputReader {
        private InputStream stream;
        private byte[] buf = new byte[1024];
        private int curChar;
        private int numChars;
        private InputReader.SpaceCharFilter filter;

        public InputReader(InputStream stream) {
            this.stream = stream;
        }

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

        public 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++];
        }

        public 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;
        }

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

        public int[] nextIntArray(int n) {
            int[] array = new int[n];
            for (int i = 0; i < n; ++i) array[i] = nextInt();
            return array;
        }

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

        }

    }
}

