#include <bits/stdc++.h>
using namespace std;
vector<int> tree[200003];
int arr[200003], st[200003], ft[200003], vt[200003], odd[3 * 200003],
    level[200003], even[3 * 200003], tim = 0;
void dfs(int n, int p, int lev = 0) {
  st[n] = ++tim;
  vt[tim] = n;
  level[n] = lev;
  for (auto x : tree[n]) {
    if (x == p) continue;
    dfs(x, n, lev + 1);
  }
  ft[n] = tim;
}
void create(int n, int st, int en) {
  if (st == en) {
    if (level[vt[st]] % 2)
      odd[n] = arr[vt[st]];
    else
      even[n] = arr[vt[st]];
    return;
  }
  int m = (st + en) >> 1;
  create(n * 2, st, m);
  create(n * 2 + 1, m + 1, en);
  odd[n] = even[n] = 0;
}
void pushdown(int n) {
  odd[n * 2] += odd[n];
  odd[n * 2 + 1] += odd[n];
  even[n * 2] += even[n];
  even[n * 2 + 1] += even[n];
  odd[n] = even[n] = 0;
}
void update(int n, int st, int en, int l, int r, int val, int lev) {
  if (st > r || en < l) return;
  if (st >= l && en <= r) {
    if (lev)
      odd[n] += val, even[n] += -val;
    else
      even[n] += val, odd[n] += -val;
    return;
  }
  pushdown(n);
  int m = (st + en) >> 1;
  update(n * 2, st, m, l, r, val, lev);
  update(n * 2 + 1, m + 1, en, l, r, val, lev);
}
int query(int n, int st, int en, int ind, int lev) {
  if (st > ind || en < ind) return 0;
  if (st == ind && en == ind) {
    if (lev)
      return odd[n];
    else
      return even[n];
  }
  pushdown(n);
  int m = (st + en) >> 1;
  return query(n * 2, st, m, ind, lev) + query(n * 2 + 1, m + 1, en, ind, lev);
}
int main() {
  int n, q, i, ty, val;
  scanf("%d %d", &n, &q);
  for (i = 1; i <= n; i++) scanf("%d", &arr[i]);
  while (--n) {
    scanf("%d %d", &i, &ty);
    tree[i].push_back(ty);
    tree[ty].push_back(i);
  }
  dfs(1, 0);
  create(1, 1, tim);
  while (q--) {
    scanf("%d %d", &ty, &n);
    if (ty == 1) {
      scanf("%d", &val);
      update(1, 1, tim, st[n], ft[n], val, level[n] % 2);
    } else
      printf("%d\n", query(1, 1, tim, st[n], level[n] % 2));
  }
  return 0;
}
