#include <bits/stdc++.h>
const int MOD = 1e9 + 7;
void M(int &x) {
  if (x >= MOD) x -= MOD;
  if (x < 0) x += MOD;
}
int qp(int a, int b = MOD - 2) {
  int ans = 1;
  for (; b; a = 1LL * a * a % MOD, b >>= 1)
    if (b & 1) ans = 1LL * ans * a % MOD;
  return ans % MOD;
}
template <class T>
T gcd(T a, T b) {
  while (b) {
    a %= b;
    std::swap(a, b);
  }
  return a;
}
template <class T>
bool chkmin(T &a, T b) {
  return a > b ? a = b, 1 : 0;
}
template <class T>
bool chkmax(T &a, T b) {
  return a < b ? a = b, 1 : 0;
}
char buf[1 << 21], *p1 = buf, *p2 = buf;
inline char getc() {
  return p1 == p2 && (p2 = (p1 = buf) + fread(buf, 1, 1 << 21, stdin), p1 == p2)
             ? EOF
             : *p1++;
}
inline int _() {
  int x = 0, f = 1;
  char ch = getc();
  while (ch < '0' || ch > '9') {
    if (ch == '-') f = -1;
    ch = getc();
  }
  while (ch >= '0' && ch <= '9') {
    x = x * 10ll + ch - 48;
    ch = getc();
  }
  return x * f;
}
const int N = 2e5 + 7;
int n, fa[N], ch[N][2], sz[N], q;
bool chk(int x) { return x == ch[fa[x]][1]; }
bool nroot(int x) { return ch[fa[x]][0] == x || ch[fa[x]][1] == x; }
void pushup(int x) { sz[x] = sz[ch[x][0]] + sz[ch[x][1]] + 1; }
void rotate(int x) {
  int y = fa[x], z = fa[y], k = chk(x), w = ch[x][k ^ 1];
  if (nroot(y)) ch[z][chk(y)] = x;
  ch[x][k ^ 1] = y;
  ch[y][k] = w;
  if (w) fa[w] = y;
  fa[y] = x;
  fa[x] = z;
  pushup(y);
  pushup(x);
}
void splay(int x) {
  while (nroot(x)) {
    int y = fa[x], z = fa[y];
    if (nroot(y)) rotate(chk(x) == chk(y) ? y : x);
    rotate(x);
  }
  pushup(x);
}
void access(int x) {
  for (int y = 0; x; x = fa[y = x]) splay(x), ch[x][1] = y, pushup(x);
}
int main() {
  n = _(), q = _();
  for (int i = (1); i < (n + 1); i++) {
    int u = _();
    sz[i] = 1;
    if (i + u <= n) fa[i] = i + u;
  }
  for (int i = (0); i < (q); i++) {
    int opt = _(), u = _();
    if (opt == 1) {
      access(u);
      int res = u;
      splay(u);
      while (ch[res][0]) res = ch[res][0];
      printf("%d %d\n", res, sz[u]);
    } else {
      int k = _();
      access(u);
      splay(u);
      ch[u][0] = fa[ch[u][0]] = 0;
      if (u + k <= n) fa[u] = u + k;
      pushup(u);
    }
  }
  return 0;
}
