Problem: Recently Duff has been a soldier in the army. Malek is her commander.

Their country, Andarz Gu has n cities (numbered from 1 to n) and n - 1 bidirectional roads. Each road connects two different cities. There exist a unique path between any two cities.

There are also m people living in Andarz Gu (numbered from 1 to m). Each person has and ID number. ID number of i - th person is i and he/she lives in city number ci. Note that there may be more than one person in a city, also there may be no people living in the city.

<image>

Malek loves to order. That's why he asks Duff to answer to q queries. In each query, he gives her numbers v, u and a.

To answer a query:

Assume there are x people living in the cities lying on the path from city v to city u. Assume these people's IDs are p1, p2, ..., px in increasing order. 

If k = min(x, a), then Duff should tell Malek numbers k, p1, p2, ..., pk in this order. In the other words, Malek wants to know a minimums on that path (or less, if there are less than a people).

Duff is very busy at the moment, so she asked you to help her and answer the queries.

Input

The first line of input contains three integers, n, m and q (1 ≤ n, m, q ≤ 105).

The next n - 1 lines contain the roads. Each line contains two integers v and u, endpoints of a road (1 ≤ v, u ≤ n, v ≠ u).

Next line contains m integers c1, c2, ..., cm separated by spaces (1 ≤ ci ≤ n for each 1 ≤ i ≤ m).

Next q lines contain the queries. Each of them contains three integers, v, u and a (1 ≤ v, u ≤ n and 1 ≤ a ≤ 10).

Output

For each query, print numbers k, p1, p2, ..., pk separated by spaces in one line.

Examples

Input

5 4 5
1 3
1 2
1 4
4 5
2 1 4 3
4 5 6
1 5 2
5 5 10
2 3 3
5 3 1


Output

1 3
2 2 3
0
3 1 2 4
1 2

Note

Graph of Andarz Gu in the sample case is as follows (ID of people in each city are written next to them):

<image>

Solution (in CPP):

Solution:
#include <bits/stdc++.h>
using namespace std;
class tree {
 public:
  int n;
  vector<vector<int>> g;
  vector<int> pv;
  vector<int> depth;
  vector<int> sz;
  vector<int> order;
  vector<int> pos;
  vector<int> end;
  int root;
  int h;
  vector<vector<int>> anc;
  tree(int _n) : n(_n) {
    g.resize(n);
    root = -1;
  }
  void add(int from, int to) {
    assert(0 <= from && from < n && 0 <= to && to < n);
    g[from].push_back(to);
    g[to].push_back(from);
  }
  void init() {
    pv = vector<int>(n, -1);
    depth = vector<int>(n, -1);
    sz = vector<int>(n);
    order.clear();
    pos = vector<int>(n, -1);
    end = vector<int>(n, -1);
  }
  void clear() {
    pv.clear();
    depth.clear();
    sz.clear();
    order.clear();
    pos.clear();
    end.clear();
    root = -1;
  }
  void dfs_from(int v) {
    init();
    root = v;
    pv[v] = -1;
    depth[v] = 0;
    dfs(v);
  }
  void prec_kth_anc() {
    assert(!pv.empty());
    int max_depth = 0;
    for (int i = 0; i < n; i++) {
      max_depth = max(max_depth, depth[i]);
    }
    for (h = 1; (1 << h) <= max_depth; h++)
      ;
    anc.resize(n);
    for (int i = 0; i < n; i++) {
      anc[i].resize(h);
      anc[i][0] = pv[i];
    }
    for (int j = 1; j < h; j++) {
      for (int i = 0; i < n; i++) {
        anc[i][j] = (anc[i][j - 1] == -1 ? -1 : anc[anc[i][j - 1]][j - 1]);
      }
    }
  }
  int go_up(int v, int up) {
    assert(!anc.empty());
    up = min(up, (1 << h) - 1);
    for (int j = h - 1; j >= 0; j--) {
      if (up & (1 << j)) {
        v = anc[v][j];
        if (v == -1) {
          break;
        }
      }
    }
    return v;
  }
  int lca(int a, int b) {
    if (depth[a] < depth[b]) {
      swap(a, b);
    }
    a = go_up(a, depth[a] - depth[b]);
    if (a == b) return a;
    for (int i = h - 1; i >= 0; i--) {
      if (anc[a][i] != anc[b][i]) {
        a = anc[a][i];
        b = anc[b][i];
      }
    }
    return anc[a][0];
  }

 private:
  void dfs(int v) {
    pos[v] = order.size();
    order.push_back(v);
    sz[v] = 1;
    for (int u : g[v]) {
      if (u == pv[v]) {
        continue;
      }
      pv[u] = v;
      depth[u] = depth[v] + 1;
      dfs(u);
      sz[v] += sz[u];
    }
    end[v] = order.size() - 1;
  }
};
const int AMAX = 10;
class segtree {
 private:
  struct node {
    vector<int> s;
    void add(const vector<int> &v) { s = v; }
    void merge(const node a, const node b) {
      int sa = a.s.size();
      int sb = b.s.size();
      int sz = min(AMAX, sa + sb);
      s.assign(sz, 0);
      int pa = 0, pb = 0;
      for (int i = 0; i < sz; i++) {
        if (pa == sa) {
          s[i] = b.s[pb++];
        } else if (pb == sb) {
          s[i] = a.s[pa++];
        } else {
          if (a.s[pa] < b.s[pb]) {
            s[i] = a.s[pa++];
          } else {
            s[i] = b.s[pb++];
          }
        }
      }
    }
  };
  int b;
  vector<node> tree;

 public:
  const int n;
  segtree(int _n) : n(_n) {
    assert(_n > 0);
    for (b = 1; b < n; b <<= 1)
      ;
    tree.resize(b << 1);
  }
  void update(int ind, const vector<int> &v) {
    assert(0 <= ind && ind < n);
    tree[b + ind].add(v);
    for (int i = (b + ind) / 2; i > 0; i >>= 1) {
      tree[i].merge(tree[i * 2], tree[i * 2 + 1]);
    }
  }
  node get(int l, int r) const {
    assert(0 <= l && l <= r && r < n);
    l += b;
    r += b;
    if (l == r) {
      return tree[l];
    }
    node left = tree[l];
    node right = tree[r];
    while (l + 1 < r) {
      if (l % 2 == 0) {
        left.merge(left, tree[l + 1]);
      }
      if (r % 2) {
        right.merge(tree[r - 1], right);
      }
      l /= 2;
      r /= 2;
    }
    node answer;
    answer.merge(left, right);
    return answer;
  }
};
int main() {
  ios::sync_with_stdio(0);
  cin.tie(0);
  int n, m, q;
  cin >> n >> m >> q;
  tree g(n);
  for (int i = 0; i < n - 1; i++) {
    int x, y;
    cin >> x >> y;
    x--;
    y--;
    g.add(x, y);
  }
  g.dfs_from(0);
  g.prec_kth_anc();
  vector<vector<int>> inv(n);
  for (int i = 0; i < m; i++) {
    int c;
    cin >> c;
    c--;
    inv[c].push_back(i + 1);
  }
  for (int i = 0; i < n; i++) {
    if ((int)inv[i].size() > AMAX) {
      inv[i].resize(AMAX);
    }
  }
  struct query {
    int v, u, a, L;
  };
  vector<query> queries;
  vector<vector<int>> qfrom(n);
  vector<vector<int>> ans(q);
  for (int i = 0; i < q; i++) {
    int v, u, a;
    cin >> v >> u >> a;
    v--;
    u--;
    queries.push_back({v, u, a, g.lca(v, u)});
    qfrom[v].push_back(i);
    qfrom[u].push_back(i);
  }
  segtree st(n);
  stack<int> stck;
  for (int v : g.order) {
    while (stck.size() && stck.top() != g.pv[v]) {
      stck.pop();
    }
    int curr = stck.size();
    assert(curr == g.depth[v]);
    stck.push(v);
    st.update(curr, inv[v]);
    for (int qid : qfrom[v]) {
      const query &qr = queries[qid];
      int from = g.depth[qr.L];
      if (from < curr) {
        auto nd = st.get(from + 1, curr);
        for (int res : nd.s) {
          ans[qid].push_back(res);
        }
      }
    }
  }
  for (int i = 0; i < q; i++) {
    const query &qr = queries[i];
    for (int res : inv[qr.L]) {
      ans[i].push_back(res);
    }
    sort(ans[i].begin(), ans[i].end());
    int SZ = min(qr.a, (int)ans[i].size());
    cout << SZ << " ";
    for (int j = 0; j < SZ; j++) {
      cout << ans[i][j] << " ";
    }
    cout << endl;
  }
}