#include <bits/stdc++.h>
using namespace std;
long long n, m, ans;
vector<long long> d0, dn;
multiset<long long> s;
vector<pair<long long, long long> > a;
vector<vector<pair<long long, long long> > > gr;
long long pos[300010];
void dfs(long long x, long long par) {
  for (auto i : gr[x]) {
    if (i.first != par) {
      dn[i.first] = dn[x] + i.second;
      dfs(i.first, x);
    }
  }
}
void er(long long x) {
  if (s.find(x) != s.end()) {
    s.erase(s.find(x));
  }
}
decltype(0) main() {
  ios_base::sync_with_stdio(false);
  cin.tie(nullptr);
  cin >> n >> m;
  gr.resize(n, a);
  for (long long i = 0; i < n - 1; ++i) {
    long long u, v, w;
    cin >> u >> v >> w;
    --u, v--;
    gr[u].push_back({v, w});
    gr[v].push_back({u, w});
  }
  dn.resize(n, 0);
  dfs(0, -1);
  d0 = dn;
  dn.clear();
  dn.resize(n, 0);
  dfs(n - 1, -1);
  for (long long i = 0; i < n; ++i) {
    a.push_back({d0[i] - dn[i], i});
    s.insert(dn[i]);
  }
  sort(a.begin(), a.end());
  for (long long i = 0; i < n; ++i) {
    pos[a[i].second] = i;
  }
  ans = 1e18;
  for (long long i = 0; i < n; ++i) {
    long long x = a[i].second;
    er(dn[x]);
    for (auto pr : gr[x]) {
      long long j = pr.first;
      if (pos[j] > i) {
        er(dn[j]);
      }
    }
    if (!s.empty()) {
      ans = min(ans, dn[0] - d0[x] - *s.rbegin());
    }
    for (auto pr : gr[x]) {
      long long j = pr.first;
      if (pos[j] > i) {
        s.insert(dn[j]);
      }
    }
  }
  for (long long i = 0; i < m; ++i) {
    long long w;
    cin >> w;
    cout << min(dn[0], dn[0] - ans + w) << "\n";
  }
}
