#include <bits/stdc++.h>
using namespace std;
const long long int mod = 1000000007;
const long long int maxn = 1e5 + 5;
const long long int N = 2e5 + 5;
long long int n, m;
long long int f[2][N];
long long int level[N];
vector<long long int> g[N];
long long int arr[N];
long long int start[N], finish[N];
long long int timer = 0;
void dfs(long long int v, long long int p) {
  level[v] = (level[p] + 1) % 2;
  start[v] = ++timer;
  for (auto u : g[v]) {
    if (u == p) continue;
    dfs(u, v);
  }
  finish[v] = timer;
}
void update(long long int idx, long long int val, long long int id) {
  while (idx < N) {
    f[id][idx] += val;
    idx += (idx & -idx);
  }
}
long long int query(long long int idx, long long int id) {
  long long int res = 0;
  while (idx > 0) {
    res += f[id][idx];
    idx -= (idx & -idx);
  }
  return res;
}
int32_t main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  cin >> n >> m;
  for (long long int i = 1; i <= n; i++) {
    cin >> arr[i];
  }
  for (long long int i = 1; i <= n - 1; i++) {
    long long int u, v;
    cin >> u >> v;
    g[u].push_back(v);
    g[v].push_back(u);
  }
  dfs(1, 0);
  while (m--) {
    long long int type;
    cin >> type;
    if (type == 1) {
      long long int v, val;
      cin >> v >> val;
      update(start[v], val, level[v]);
      update(finish[v] + 1, -val, level[v]);
      update(start[v], -val, 1 - level[v]);
      update(finish[v] + 1, val, 1 - level[v]);
    } else {
      long long int v;
      cin >> v;
      cout << query(start[v], level[v]) + arr[v] << '\n';
    }
  }
}
