#include <bits/stdc++.h>
using namespace std;
using LL = long long;
void Print() { cout << endl; }
template <typename T1, typename... T>
void Print(const T1 &t1, const T &...t) {
  cout << t1 << " ";
  Print(t...);
}
template <typename T1, typename T2>
ostream &operator<<(ostream &os, const pair<T1, T2> &p) {
  os << "(" << p.first << ", " << p.second << ")";
  return os;
}
template <class Iterator>
ostream &output_cantainer(ostream &os, Iterator first, Iterator last,
                          bool space = true) {
  if (space) {
    for (Iterator it = first; it != last; it++) {
      os << (*it) << ' ';
    }
    os << endl;
  } else
    for (Iterator it = first; it != last; it++) {
      os << (*it) << endl;
    }
  return os;
}
const int N = 2e5 + 4;
int a[N], par[N], dep[N];
LL v[N << 2];
int n, nxt, s[N], e[N];
vector<int> ed[N];
void update(int id, int l, int r, int x, int y, int val) {
  if (l > y || r < x) return;
  if (x <= l && r <= y) {
    v[id] += val;
    return;
  }
  int m = (l + r) >> 1;
  update(id << 1, l, m, x, y, val);
  update(id << 1 | 1, m + 1, r, x, y, val);
}
LL query(int id, int l, int r, int x) {
  if (l == r) return v[id];
  int m = (l + r) >> 1;
  if (x <= m) return v[id] + query(id << 1, l, m, x);
  return v[id] + query(id << 1 | 1, m + 1, r, x);
}
void dfs(int x) {
  s[x] = nxt + 1;
  for (int to : ed[x]) {
    if (par[x] == to) continue;
    dep[to] = dep[x] + 1;
    par[to] = x;
    dfs(to);
  }
  e[x] = ++nxt;
}
int main() {
  int m;
  scanf("%d%d", &n, &m);
  for (int i = 1; i <= n; i++) scanf("%d", a + i);
  for (int i = 0; i < n - 1; i++) {
    int s, t;
    scanf("%d%d", &s, &t);
    ed[s].push_back(t);
    ed[t].push_back(s);
  }
  dfs(1);
  while (m--) {
    int op;
    scanf("%d", &op);
    if (op == 1) {
      int x, y;
      scanf("%d%d", &x, &y);
      update(1, 1, n, s[x], e[x], (dep[x] & 1) ? -y : y);
    } else {
      int x;
      scanf("%d", &x);
      LL val = query(1, 1, n, e[x]);
      printf("%lld\n", (dep[x] & 1) ? (a[x] - val) : (a[x] + val));
    }
  }
}
