#include <bits/stdc++.h>
using namespace std;
int a[100010];
int b[100010];
int main() {
  int n, i, k, j, t, inc, dec, nk, ok, ans1, ans2, ans3;
  int dhor, now;
  while (scanf("%d", &n) == 1) {
    nk = 0;
    for (i = 0; i < n; i++) {
      scanf("%d", &a[i]);
      if (i == 0)
        b[nk++] = a[i];
      else {
        if (b[nk - 1] != a[i]) b[nk++] = a[i];
      }
    }
    ok = 1;
    for (i = 1; i < nk - 1; i++) {
      if (b[i] > b[i - 1] && b[i] > b[i + 1]) {
        ok = 0;
        dhor = i + 1;
        break;
      } else if (b[i] < b[i - 1] && b[i] < b[i + 1]) {
        ok = 0;
        dhor = i + 1;
        break;
      }
    }
    if (ok) {
      printf("0\n");
    } else {
      now = 1;
      for (i = 1; i < n; i++) {
        if (a[i] != a[i - 1]) now++;
        if (now == dhor) break;
      }
      ans1 = i - 1;
      ans2 = i;
      j = i;
      while (a[j] == a[i]) j++;
      ans3 = j;
      printf("3\n%d %d %d\n", ans1 + 1, ans2 + 1, ans3 + 1);
    }
  }
  return 0;
}
