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.PrintWriter;
import java.util.HashSet;
import java.io.FilterInputStream;
import java.io.BufferedInputStream;
import java.io.InputStream;

/**
 * @author khokharnikunj8
 */

public class Main {
    public static void main(String[] args) {
        new Thread(null, new Runnable() {
            public void run() {
                new Main().solve();
            }
        }, "1", 1 << 26).start();
    }

    void solve() {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        ScanReader in = new ScanReader(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
        DPairOfNumbers solver = new DPairOfNumbers();
        solver.solve(1, in, out);
        out.close();
    }

    static class DPairOfNumbers {
        int[] t;
        int n;

        void build() {
            for (int i = n - 1; i > 0; --i) t[i] = CodeHash.gcd(t[i << 1], t[i << 1 | 1]);
        }

        int query(int l, int r) {
            int res = 0;
            for (l += n, r += n + 1; l < r; l >>= 1, r >>= 1) {
                if ((l & 1) != 0) res = CodeHash.gcd(res, t[l++]);
                if ((r & 1) != 0) res = CodeHash.gcd(res, t[--r]);
            }
            return res;
        }

        public void solve(int testNumber, ScanReader in, PrintWriter out) {
            int max = -1;
            HashSet<Integer> ans = new HashSet<>();
            n = in.scanInt();
            int[] ar = new int[n];
            t = new int[2 * (n + 1)];
            for (int i = 0; i < n; i++) t[n + i] = ar[i] = in.scanInt();
            build();
            for (int i = 0; i < n; i++) {
                int low = 0;
                int high = i;
                int indexL = -1;
                while (low <= high) {
                    int mid = (high + low) >> 1;
                    if (query(mid, i) % ar[i] == 0) {
                        indexL = mid;
                        high = mid - 1;
                    } else low = mid + 1;
                }
                int low1 = i;
                int high1 = n - 1;
                int indexR = -1;
                while (low1 <= high1) {
                    int mid = (low1 + high1) >> 1;
                    if (query(i, mid) % ar[i] == 0) {
                        indexR = mid;
                        low1 = mid + 1;
                    } else high1 = mid - 1;
                }
                if (indexR - indexL > max) {
                    ans.clear();
                    ans.add(indexL + 1);
                    max = indexR - indexL;
                } else if (indexR - indexL == max) ans.add(indexL + 1);
            }
            out.println(ans.size() + " " + (max));
            int[] tt = new int[ans.size()];
            int tl = 0;
            for (int i : ans) tt[tl++] = i;
            CodeHash.Radix_Sort(tt);
            for (int i : tt) out.print(i + " ");

        }

    }

    static class CodeHash {
        public static void Radix_Sort(int a[]) {

            int multiplier = 1, len = a.length, max = Integer.MIN_VALUE;
            int b[] = new int[len];
            int bucket[];
            for (int i = 0; i < len; i++) if (max < a[i]) max = a[i];
            while (max / multiplier > 0) {
                bucket = new int[10];
                for (int i = 0; i < len; i++) bucket[(a[i] / multiplier) % 10]++;
                for (int i = 1; i < 10; i++) bucket[i] += (bucket[i - 1]);
                for (int i = len - 1; i >= 0; i--) b[--bucket[(a[i] / multiplier) % 10]] = a[i];
                for (int i = 0; i < len; i++) a[i] = b[i];
                multiplier *= 10;
            }

        }

        public static int gcd(int a, int b) {
            while (b != 0) {
                int t = b;
                b = (a % b);
                a = t;
            }
            return a;
        }

    }

    static class ScanReader {
        private byte[] buf = new byte[4 * 1024];
        private int index;
        private BufferedInputStream in;
        private int total;

        public ScanReader(InputStream inputStream) {
            in = new BufferedInputStream(inputStream);
        }

        private int scan() {
            if (index >= total) {
                index = 0;
                try {
                    total = in.read(buf);
                } catch (Exception e) {
                    e.printStackTrace();
                }
                if (total <= 0) return -1;
            }
            return buf[index++];
        }

        public int scanInt() {
            int integer = 0;
            int n = scan();
            while (isWhiteSpace(n)) n = scan();
            int neg = 1;
            if (n == '-') {
                neg = -1;
                n = scan();
            }
            while (!isWhiteSpace(n)) {
                if (n >= '0' && n <= '9') {
                    integer *= 10;
                    integer += n - '0';
                    n = scan();
                }
            }
            return neg * integer;
        }

        private boolean isWhiteSpace(int n) {
            if (n == ' ' || n == '\n' || n == '\r' || n == '\t' || n == -1) return true;
            else return false;
        }

    }
}

