#include <bits/stdc++.h>
using namespace std;
const int N = 4e5 + 10;
vector<int> adj[N];
int order[N], from[N], to[N], T = 1, n, m, a[N], d[N];
long long BIT[2][N];
void DFS(int u, int p) {
  order[T] = u;
  from[u] = T++;
  for (int i = 0; i < adj[u].size(); ++i)
    if (p != adj[u][i]) {
      d[adj[u][i]] = 1 + d[u];
      DFS(adj[u][i], u);
    }
  to[u] = T - 1;
}
void update(long long* BIT, int idx, int val) {
  while (idx < N) {
    BIT[idx] += val;
    idx += idx & -idx;
  }
}
long long get(long long* BIT, int idx) {
  long long res = 0;
  while (idx) {
    res += BIT[idx];
    idx -= idx & -idx;
  }
  return res;
}
int main() {
  scanf("%d%d", &n, &m);
  for (int i = 0; i < n; ++i) scanf("%d", a + i + 1);
  for (int i = 1; i < n; ++i) {
    int u, v;
    scanf("%d%d", &u, &v);
    adj[u].push_back(v);
    adj[v].push_back(u);
  }
  DFS(1, -1);
  while (m--) {
    int x;
    scanf("%d", &x);
    if (x == 1) {
      int u, val;
      scanf("%d%d", &u, &val);
      int l = from[u];
      int r = to[u];
      if (d[u] & 1) {
        update(BIT[1], l, val);
        update(BIT[1], r + 1, -val);
        update(BIT[0], l, -val);
        update(BIT[0], r + 1, val);
      } else {
        update(BIT[0], l, val);
        update(BIT[0], r + 1, -val);
        update(BIT[1], l, -val);
        update(BIT[1], r + 1, val);
      }
    } else {
      int x;
      scanf("%d", &x);
      int l = from[x];
      printf("%lld\n", a[x] + get(BIT[d[x] & 1], l));
    }
  }
  return 0;
}
