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.io.Writer;
import java.io.OutputStreamWriter;
import java.util.InputMismatchException;
import java.io.IOException;
import java.io.InputStream;

/**
 * Built using CHelper plug-in
 * Actual solution is at the top
 *
 * @author Arthur Gazizov - Kazan FU #4.3 [2oo7]
 */
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);
        TaskD solver = new TaskD();
        solver.solve(1, in, out);
        out.close();
    }

    static class TaskD {
        TaskD.sparseTable sparseTable;
        int[] a;
        int n;

        boolean f(int length) {
            for (int left = 0; left < a.length - length; left++) {
                int right = left + length + 1;
                int min = sparseTable.getMin(left, right);
                int gcd = sparseTable.getGCD(left, right);
                if (min == gcd) {
                    return true;
                }
            }
            return false;
        }

        public void solve(int testNumber, InputReader in, OutputWriter out) {
            n = in.nextInt();
            a = IOUtils.readIntArray(in, n);
            sparseTable = new TaskD.sparseTable(a);
            int left = 1;
            int right = a.length;
            while (right - left > 1) {
                int middle = (right + left) / 2;
                if (f(middle)) {
                    left = middle;
                } else {
                    right = middle;
                }
            }
            while (!f(right)) right--;
            int length = right;
            int count = 0;
            StringBuilder builder = new StringBuilder();
            for (int i = 0; i < a.length - length; i++) {
                int min = sparseTable.getMin(i, i + length + 1);
                int gcd = sparseTable.getGCD(i, i + length + 1);
                if (min == gcd) {
                    count++;
                    builder.append(i + 1)
                            .append(' ');
                }
            }
            out.prints(count)
                    .printLine(length);
            out.print(builder.toString());
        }

        static class sparseTable {
            private int[][] a;
            private int[][] b;
            private int[] deg;

            public sparseTable(int[] array) {
                int n = array.length;
                int log = 1;
                while ((1 << (log - 1)) < n) {
                    log++;
                }
                a = new int[log][];
                b = new int[log][];
                a[0] = array.clone();
                b[0] = array.clone();
                for (int i = 1; i < log; i++) {
                    int halfLen = 1 << (i - 1);
                    a[i] = new int[n];
                    b[i] = new int[n];
                    for (int j = 0; j + halfLen < a[i].length; j++) {
                        a[i][j] = Math.min(a[i - 1][j], a[i - 1][j + halfLen]);
                        b[i][j] = IntegerUtils.gcd(b[i - 1][j], b[i - 1][j + halfLen]);
                    }
                }
                deg = new int[n + 1];
                for (int i = 2; i <= n; i++) {
                    deg[i] = 1 + deg[i >> 1];
                }
            }

            public int getMin(int left, int right) {
                int i = deg[right - left];
                return Math.min(a[i][left], a[i][right - (1 << i)]);
            }

            public int getGCD(int left, int right) {
                int i = deg[right - left];
                return IntegerUtils.gcd(b[i][left], b[i][right - (1 << i)]);
            }

        }

    }

    static class IOUtils {
        public static int[] readIntArray(InputReader in, int size) {
            int[] array = new int[size];
            for (int i = 0; i < size; i++) {
                array[i] = in.nextInt();
            }
            return array;
        }

    }

    static class IntegerUtils {
        public static int gcd(int a, int b) {
            a = Math.abs(a);
            b = Math.abs(b);
            while (b != 0) {
                int temp = a % b;
                a = b;
                b = temp;
            }
            return a;
        }

    }

    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 close() {
            writer.close();
        }

        public OutputWriter prints(int i) {
            writer.print(i);
            writer.print(' ');
            return this;
        }

        public void printLine(int i) {
            writer.println(i);
        }

    }

    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 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 static boolean isWhitespace(int c) {
            return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
        }

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

        }

    }
}

