#include <bits/stdc++.h>
using namespace std;
const int MAX = 2e5 + 10;
int inf = (int)3e15;
int mod = (int)1e9 + 7;
int sz = 500, timer = 0;
vector<int> gr[MAX];
int n, q, odd[MAX], even[MAX], h[MAX], tin[MAX], tout[MAX], mus[MAX], o[MAX];
vector<pair<int, int>> tmp;
void calc(int v, int p) {
  tin[v] = ++timer;
  h[v] = h[p] + 1;
  for (auto u : gr[v]) {
    if (u != p) calc(u, v);
  }
  tout[v] = ++timer;
}
void dfs_rebuild(int v, int p) {
  odd[v] += even[p];
  even[v] += odd[p];
  for (auto u : gr[v]) {
    if (u != p) dfs_rebuild(u, v);
  }
}
void rebuild() {
  for (int i = 1; i <= n; i++) {
    even[i] = 0;
    odd[i] = 0;
  }
  for (int i = 0; i < tmp.size(); i++) mus[tmp[i].first] += tmp[i].second;
  for (int i = 1; i <= n; i++) even[i] = mus[i];
  tmp.clear();
  dfs_rebuild(1, 0);
}
void out_val(int v) {
  int ans = even[v] - odd[v] + o[v];
  for (int i = 0; i < tmp.size(); i++) {
    int u = tmp[i].first;
    int val = tmp[i].second;
    if (tin[u] <= tin[v] && tout[u] >= tout[v]) {
      if ((h[v] - h[u]) % 2 == 1)
        ans -= val;
      else
        ans += val;
    }
  }
  cout << ans << "\n";
}
void solve() {
  cin >> n >> q;
  for (int i = 1; i <= n; i++) {
    cin >> o[i];
  }
  for (int i = 0; i < n - 1; i++) {
    int a, b;
    cin >> a >> b;
    gr[a].push_back(b);
    gr[b].push_back(a);
  }
  calc(1, 0);
  for (int i = 0; i < q; i++) {
    int a;
    cin >> a;
    if (a == 1) {
      int b, c;
      cin >> b >> c;
      tmp.push_back({b, c});
      if (tmp.size() == 2000) rebuild();
    } else {
      int c;
      cin >> c;
      out_val(c);
    }
  }
}
int main() {
  ios::sync_with_stdio(0);
  int q;
  q = 1;
  while (q--) {
    solve();
  }
  return 0;
}
