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 QueryTree {
 private:
  int n, root;
  vector<vector<int> > G, L;
  vector<int> in, out, dist;
  vector<vector<int> > people;
  vector<vector<priority_queue<int> > > sets;
  void DFSv(int v, int par, int &t) {
    in[v] = t++;
    for (int i = (0); i <= ((int)(G[v]).size() - 1); ++i)
      if (G[v][i] != par) {
        int u = G[v][i];
        L[u][0] = v;
        dist[u] = dist[v] + 1;
        for (int j = (1); j <= ((int)(L[i]).size() - 1); ++j) {
          int up = L[u][j - 1];
          if (up != -1) L[u][j] = L[up][j - 1];
          sets[u][j] = sets[u][j - 1];
          if (up != -1) {
            priority_queue<int> temp = sets[up][j - 1];
            while (!temp.empty()) {
              sets[u][j].push(temp.top());
              temp.pop();
            }
            fixSet(sets[u][j]);
          }
        }
        DFSv(u, v, t);
      }
    out[v] = t++;
  }

 public:
  QueryTree(vector<vector<int> > &G, vector<vector<int> > &people) {
    this->n = (int)(G).size();
    this->root = 0;
    this->G = G;
    this->people = people;
    L.resize(n);
    sets.resize(n);
    in.resize(n);
    out.resize(n);
    dist.resize(n, 0);
    int t = 0;
    int p = 1, k = 0;
    while (p < n) {
      p *= 2;
      ++k;
    }
    for (int i = (0); i <= ((int)(L).size() - 1); ++i) L[i].resize(k, -1);
    for (int i = (0); i <= ((int)(sets).size() - 1); ++i) sets[i].resize(k);
    for (int i = (0); i <= ((int)(sets).size() - 1); ++i) {
      if (i) {
        for (int person : people[i]) sets[i][0].push(person);
      } else {
        for (int person : people[i])
          for (int j = (0); j <= (k - 1); ++j) sets[0][j].push(person);
      }
    }
    for (int i = (0); i <= ((int)(sets).size() - 1); ++i)
      for (int j = (0); j <= ((int)(sets[i]).size() - 1); ++j)
        fixSet(sets[i][j]);
    DFSv(root, -1, t);
  }
  void fixSet(priority_queue<int> &S, int toSize = 10) {
    while ((int)(S).size() > toSize) S.pop();
  }
  bool isAnc(int x, int y) {
    return (x == -1) || ((in[x] <= in[y]) && (out[x] >= out[y]));
  }
  int getLCA(int a, int b) {
    if (isAnc(a, b))
      return a;
    else if (isAnc(b, a))
      return b;
    int k = (int)(L[a]).size() - 1;
    while (k >= 0) {
      if (isAnc(L[a][k], b))
        k--;
      else
        a = L[a][k];
    }
    return L[a][0];
  }
  void queryUp(int a, int up, priority_queue<int> &ans) {
    if (a == up) return;
    int k = (int)(L[a]).size() - 1;
    while (k >= 0) {
      if (isAnc(L[a][k], up))
        k--;
      else {
        priority_queue<int> temp = sets[a][k];
        while (!temp.empty()) {
          ans.push(temp.top());
          temp.pop();
        }
        fixSet(ans);
        a = L[a][k];
      }
    }
    priority_queue<int> temp = sets[a][0];
    while (!temp.empty()) {
      ans.push(temp.top());
      temp.pop();
    }
  }
  void query(int a, int b, int toSize, priority_queue<int> &ans) {
    int lca = getLCA(a, b);
    for (int person : people[lca]) ans.push(person);
    queryUp(a, lca, ans);
    queryUp(b, lca, ans);
    fixSet(ans, toSize);
  }
};
int main() {
  ios_base::sync_with_stdio(0);
  int n, m, q;
  cin >> n >> m >> q;
  vector<vector<int> > G(n);
  for (int i = (1); i <= (n - 1); ++i) {
    int u, v;
    cin >> u >> v;
    u--;
    v--;
    G[u].push_back(v);
    G[v].push_back(u);
  }
  vector<vector<int> > people(n);
  for (int i = (1); i <= (m); ++i) {
    int city;
    cin >> city;
    city--;
    people[city].push_back(i);
  }
  for (int i = (0); i <= (n - 1); ++i)
    if ((int)(people[i]).size() > 10) {
      sort(people[i].begin(), people[i].end());
      while ((int)(people[i]).size() > 10) people[i].pop_back();
    }
  QueryTree Tree(G, people);
  while (q--) {
    int v, u, a;
    cin >> v >> u >> a;
    v--;
    u--;
    priority_queue<int> ans;
    Tree.query(v, u, a, ans);
    vector<int> vec;
    while (!ans.empty()) {
      vec.push_back(ans.top());
      ans.pop();
    }
    cout << (int)(vec).size() << ' ';
    for (int i = ((int)(vec).size() - 1); i >= (0); --i) cout << vec[i] << ' ';
    cout << '\n';
  }
  return 0;
}