#include <bits/stdc++.h>
using namespace std;
const int N = 4e5 + 10;
int color[N], tin[N], tout[N], mp[N], bit1[N], bit2[N], level[N];
int n, m, timer;
vector<int> g[N];
void update(int i, int x, int bit[]) {
  while (i <= N) {
    bit[i] += x;
    i = i + (i & (-i));
  }
}
int sum(int i, int bit[]) {
  int ans = 0;
  while (i != 0 && i > 0) {
    ans += bit[i];
    i = (i & (i - 1));
  }
  return ans;
}
void dfs(int v, int p) {
  tin[v] = ++timer;
  mp[timer] = v;
  for (auto it : g[v]) {
    if (it == p) continue;
    level[it] = level[v] ^ 1;
    dfs(it, v);
  }
  tout[v] = timer;
}
int main() {
  scanf("%d %d", &n, &m);
  for (int i = 1; i <= n; ++i) {
    scanf("%d", color + i);
  }
  for (int i = 0; i < n - 1; ++i) {
    int x, y;
    scanf("%d %d", &x, &y);
    g[x].push_back(y);
    g[y].push_back(x);
  }
  dfs(1, 0);
  for (int i = 1; i <= n; ++i) {
    if (level[i] == 0) {
      update(tin[i], color[i], bit1);
      update(tin[i] + 1, -1 * color[i], bit1);
    } else {
      update(tin[i], color[i], bit2);
      update(tin[i] + 1, -1 * color[i], bit2);
    }
  }
  while (m--) {
    int type, v, c;
    scanf("%d", &type);
    if (type == 1) {
      scanf("%d %d", &v, &c);
      if (level[v] == 0) {
        update(tin[v], c, bit1);
        update(tout[v] + 1, -1 * c, bit1);
        update(tin[v], -1 * c, bit2);
        update(tout[v] + 1, c, bit2);
      } else {
        update(tin[v], c, bit2);
        update(tout[v] + 1, -1 * c, bit2);
        update(tin[v], -1 * c, bit1);
        update(tout[v] + 1, c, bit1);
      }
    } else {
      scanf("%d", &v);
      if (level[v] == 0) {
        printf("%d\n", sum(tin[v], bit1));
      } else
        printf("%d\n", sum(tin[v], bit2));
    }
  }
}
