#include <bits/stdc++.h>
using namespace std;
mt19937 Rand(time(0));
const int maxn = 3e5 + 5;
const long long maxc = 1e18 + 7;
int n, m;
vector<pair<int, int>> adj[maxn];
long long disOne[maxn], disN[maxn], dis[maxn];
long long diff, mindis;
void dfs(int u, int par = -1) {
  for (__typeof((adj[u]).begin()) it = (adj[u]).begin(); it != (adj[u]).end();
       ++it) {
    if (it->first == par) continue;
    dis[it->first] = dis[u] + it->second;
    dfs(it->first, u);
  }
}
int order[maxn], pos[maxn];
void caldiff() {
  iota(order + 1, order + n + 1, 1);
  sort(order + 1, order + n + 1,
       [](int i, int j) { return disOne[i] - disN[i] < disOne[j] - disN[j]; });
  for (int i = (1); i <= (n); ++i) pos[order[i]] = i;
  multiset<long long, greater<long long>> s;
  for (int i = (1); i <= (n); ++i) s.insert(disN[i]);
  diff = maxc;
  for (int i = (1); i <= (n); ++i) {
    int u = order[i];
    s.erase(s.find(disN[u]));
    for (__typeof((adj[u]).begin()) it = (adj[u]).begin(); it != (adj[u]).end();
         ++it) {
      if (pos[it->first] > pos[u]) s.erase(s.find(disN[it->first]));
    }
    if (s.size()) diff = min(diff, mindis - (disOne[u] + *s.begin()));
    for (__typeof((adj[u]).begin()) it = (adj[u]).begin(); it != (adj[u]).end();
         ++it) {
      if (pos[it->first] > pos[u]) s.insert(disN[it->first]);
    }
  }
}
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  cin >> n >> m;
  for (int i = (1); i <= (n - 1); ++i) {
    int u, v, c;
    cin >> u >> v >> c;
    adj[u].push_back(make_pair(v, c));
    adj[v].push_back(make_pair(u, c));
  }
  dfs(1);
  for (int i = (1); i <= (n); ++i) {
    disOne[i] = dis[i];
    dis[i] = 0;
  }
  mindis = disOne[n];
  dfs(n);
  for (int i = (1); i <= (n); ++i) {
    disN[i] = dis[i];
    dis[i] = 0;
  }
  caldiff();
  while (m--) {
    int x;
    cin >> x;
    cout << min(mindis, mindis - diff + x) << "\n";
  }
  return 0;
}
