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;
vector<int> g[100001];
vector<int> c[100001];
int t[100001];
int p[20][100001];
int L[100001];
int pw[20];
vector<int> seq[20][100001];
void go(int n, int par, int lev) {
  t[n] = par;
  L[n] = lev;
  for (int i = 0; i < g[n].size(); i++) {
    if (g[n][i] != par) go(g[n][i], n, lev + 1);
  }
}
void pre1(int n) {
  for (int i = 1; i <= n; i++) {
    for (int j = 0; j < 20; j++) {
      p[j][i] = -1;
    }
  }
  for (int i = 1; i <= n; i++) p[0][i] = t[i];
  for (int j = 1; 1 << j <= n; j++)
    for (int i = 1; i <= n; i++)
      if (p[j - 1][i] != -1) p[j][i] = p[j - 1][p[j - 1][i]];
}
int lca(int n, int x, int y) {
  int tmp, lg, i;
  if (L[x] < L[y]) tmp = x, x = y, y = tmp;
  for (lg = 1; 1 << lg <= L[x]; lg++)
    ;
  lg--;
  for (i = lg; i >= 0; i--)
    if (L[x] - (1 << i) >= L[y]) x = p[i][x];
  if (x == y) return x;
  for (i = lg; i >= 0; i--)
    if (p[i][x] != -1 && p[i][x] != p[i][y]) x = p[i][x], y = p[i][y];
  return t[x];
}
void pre2(int n) {
  for (int i = 1; i <= n; i++) {
    for (int j = 0; j < c[t[i]].size(); j++) {
      seq[0][i].push_back(c[t[i]][j]);
    }
    sort(seq[0][i].begin(), seq[0][i].end());
    if (seq[0][i].size() > 10)
      seq[0][i].erase(seq[0][i].begin() + 10, seq[0][i].end());
  }
  for (int j = 1; 1 << j <= n; j++)
    for (int i = 1; i <= n; i++)
      if (p[j - 1][i] != -1) {
        for (int k = 0; k < seq[j - 1][i].size(); k++) {
          seq[j][i].push_back(seq[j - 1][i][k]);
        }
        for (int k = 0; k < seq[j - 1][p[j - 1][i]].size(); k++) {
          seq[j][i].push_back(seq[j - 1][p[j - 1][i]][k]);
        }
        sort(seq[j][i].begin(), seq[j][i].end());
        if (seq[j][i].size() > 10)
          seq[j][i].erase(seq[j][i].begin() + 10, seq[j][i].end());
      }
}
vector<int> query(int n, int x, int y) {
  int lg = 0;
  for (; 1 << lg <= n; lg++)
    ;
  lg--;
  vector<int> res;
  for (int i = 0; i < c[x].size(); i++) res.push_back(c[x][i]);
  while (y && lg >= 0) {
    if (pw[lg] > y) {
      lg--;
    } else {
      y -= (pw[lg]);
      for (int i = 0; i < seq[lg][x].size(); i++) res.push_back(seq[lg][x][i]);
      x = p[lg][x];
      lg--;
    }
  }
  return res;
}
int main(int argc, char const *argv[]) {
  pw[0] = 1;
  for (int i = 1; i < 20; i++) pw[i] = pw[i - 1] * 2;
  int n, m, q;
  scanf("%d%d%d", &n, &m, &q);
  for (int i = 0; i < n - 1; i++) {
    int u, v;
    scanf("%d%d", &u, &v);
    g[u].push_back(v);
    g[v].push_back(u);
  }
  for (int i = 1; i <= m; i++) {
    int x;
    scanf("%d", &x);
    c[x].push_back(i);
    sort(c[x].begin(), c[x].end());
    if (c[x].size() > 10) {
      c[x].erase(c[x].begin() + 10, c[x].end());
    }
  }
  go(1, 1, 0);
  pre1(n);
  pre2(n);
  while (q--) {
    int u, v, a;
    scanf("%d%d%d", &u, &v, &a);
    if (u == v) {
      int ans = min((int)c[u].size(), a);
      printf("%d ", ans);
      for (int i = 0; i < ans; i++) printf("%d ", c[u][i]);
      printf("\n");
      continue;
    }
    int tmp;
    if (L[u] > L[v]) tmp = u, u = v, v = tmp;
    int lcapar = lca(n, u, v);
    vector<int> ans1 = query(n, u, L[u] - L[lcapar]);
    vector<int> ans2 = query(n, v, L[v] - L[lcapar] - 1);
    for (int i = 0; i < ans1.size(); i++) {
      ans2.push_back(ans1[i]);
    }
    sort(ans2.begin(), ans2.end());
    int ans = min((int)ans2.size(), a);
    printf("%d ", ans);
    for (int i = 0; i < ans; i++) printf("%d ", ans2[i]);
    printf("\n");
  }
  return 0;
}