#include <bits/stdc++.h>
using namespace std;
const long long MOD = 1e9 + 7;
const int INF = 2e9;
const long long INF64 = 1e18;
const long double EPS = 1e-12;
const long double PI = 3.1415926535897932384626433832795028841;
const long long MD = 925262732;
const long long T = 634521;
const int N = 400100;
const int M = 301;
struct tree {
  long long t[N * 8];
  tree() {
    for (int i = 0; i < int(N * 8); i++) t[i] = 0;
  }
  void push(int v, int tl, int tr) {
    if (tl != tr) {
      t[v * 2] += t[v];
      t[v * 2 + 1] += t[v];
      t[v] = 0;
    }
  }
  void update(int v, int tl, int tr, int l, int r, long long val) {
    push(v, tl, tr);
    if (l > r) return;
    if (tl == l && tr == r) {
      t[v] += val;
      return;
    }
    int tm = (tl + tr) / 2;
    update(v * 2, tl, tm, l, min(r, tm), val);
    update(v * 2 + 1, tm + 1, tr, max(l, tm + 1), r, val);
  }
  long long get(int v, int tl, int tr, int ind) {
    push(v, tl, tr);
    if (tl == tr) return t[v];
    int tm = (tl + tr) / 2;
    if (ind <= tm)
      return get(v * 2, tl, tm, ind);
    else
      return get(v * 2 + 1, tm + 1, tr, ind);
  }
} t0, t1;
long long n, m, tin[N], tout[N], a[N], timer = 1, h[N];
vector<int> g[N];
void dfs(int v, int hh = 1) {
  h[v] = hh;
  tin[v] = timer++;
  for (int i = 0; i < int(int((g[v]).size())); i++)
    if (!tin[g[v][i]]) dfs(g[v][i], hh + 1);
  tout[v] = timer++;
}
int main() {
  ios_base::sync_with_stdio(0);
  cin >> n >> m;
  for (int i = 1; i <= n; i++) cin >> a[i];
  for (int i = 0; i < int(n - 1); i++) {
    int first, second;
    cin >> first >> second;
    g[first].push_back(second);
    g[second].push_back(first);
  }
  dfs(1);
  for (int i = 0; i < int(m); i++) {
    int t;
    cin >> t;
    if (t == 1) {
      int first, second;
      cin >> first >> second;
      if (h[first] & 1) {
        t1.update(1, 1, N - 1, tin[first], tout[first], second);
        t0.update(1, 1, N - 1, tin[first], tout[first], -second);
      } else {
        t1.update(1, 1, N - 1, tin[first], tout[first], -second);
        t0.update(1, 1, N - 1, tin[first], tout[first], second);
      }
    } else {
      int first;
      cin >> first;
      long long ans = a[first];
      if (h[first] & 1)
        ans += t1.get(1, 1, N - 1, tin[first]);
      else
        ans += t0.get(1, 1, N - 1, tin[first]);
      cout << ans << endl;
    }
  }
  return 0;
}
