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> adj[100009], MSOLD[100009][20], SOLD[100009], ANS, TMP;
int P[100009][20], T[100009], color[100009], L[100009], dis[100009], ten = 10;
queue<int> Q;
void bfs(int s) {
  while (!Q.empty()) Q.pop();
  int a, d, f, g, h, j, k, l;
  Q.push(s);
  color[s] = 1;
  dis[s] = 0;
  T[s] = -1;
  L[s] = 0;
  while (!Q.empty()) {
    d = Q.front();
    Q.pop();
    for (a = 0; a < adj[d].size(); a++) {
      if (color[adj[d][a]] == 0) {
        color[adj[d][a]] = 1;
        Q.push(adj[d][a]);
        dis[adj[d][a]] = dis[d] + 1;
        L[adj[d][a]] = dis[adj[d][a]];
        T[adj[d][a]] = d;
      }
    }
  }
}
void query(int N, int p, int q) {
  int tmp, log, i, I, J, curr_parent, minans, maxans, l, temp_size, cnt;
  ANS.clear();
  TMP.clear();
  temp_size = SOLD[p].size();
  for (i = 0; i < temp_size; i++) TMP.push_back(SOLD[p][i]);
  temp_size = SOLD[q].size();
  for (i = 0; i < temp_size; i++) TMP.push_back(SOLD[q][i]);
  cnt = 0;
  sort(TMP.begin(), TMP.end());
  temp_size = TMP.size();
  if (temp_size) {
    ANS.push_back(TMP[0]);
    cnt++;
  }
  for (l = 1; l < temp_size; l++) {
    if (TMP[l] != TMP[l - 1]) {
      cnt++;
      ANS.push_back(TMP[l]);
      if (cnt == ten) break;
    }
  }
  I = p;
  J = q;
  if (L[p] < L[q]) {
    tmp = p, p = q, q = tmp;
  }
  for (log = 1; 1 << log <= L[p]; log++)
    ;
  log--;
  for (i = log; i >= 0; i--) {
    if (L[p] - (1 << i) >= L[q]) {
      p = P[p][i];
    }
  }
  if (p == q)
    curr_parent = p;
  else {
    for (i = log; i >= 0; i--) {
      if (P[p][i] != -1 && P[p][i] != P[q][i]) {
        p = P[p][i], q = P[q][i];
      }
    }
    curr_parent = T[p];
  }
  for (log = 1; 1 << log <= L[I]; log++)
    ;
  log--;
  p = I;
  q = J;
  for (i = log; i >= 0; i--) {
    if (P[p][i] != -1) {
      if (L[curr_parent] <= L[P[p][i]]) {
        TMP.clear();
        TMP = ANS;
        temp_size = MSOLD[p][i].size();
        for (l = 0; l < temp_size; l++) TMP.push_back(MSOLD[p][i][l]);
        ANS.clear();
        cnt = 0;
        sort(TMP.begin(), TMP.end());
        temp_size = TMP.size();
        if (temp_size) {
          ANS.push_back(TMP[0]);
          cnt++;
        }
        for (l = 1; l < temp_size; l++) {
          if (TMP[l] != TMP[l - 1]) {
            cnt++;
            ANS.push_back(TMP[l]);
            if (cnt == ten) break;
          }
        }
        p = P[p][i];
      }
    }
  }
  swap(I, J);
  p = I;
  q = J;
  for (log = 1; 1 << log <= L[I]; log++)
    ;
  log--;
  for (i = log; i >= 0; i--) {
    if (P[p][i] != -1) {
      if (L[curr_parent] <= L[P[p][i]]) {
        TMP.clear();
        TMP = ANS;
        temp_size = MSOLD[p][i].size();
        for (l = 0; l < temp_size; l++) TMP.push_back(MSOLD[p][i][l]);
        ANS.clear();
        cnt = 0;
        sort(TMP.begin(), TMP.end());
        temp_size = TMP.size();
        if (temp_size) {
          ANS.push_back(TMP[0]);
          cnt++;
        }
        for (l = 1; l < temp_size; l++) {
          if (TMP[l] != TMP[l - 1]) {
            cnt++;
            ANS.push_back(TMP[l]);
            if (cnt == ten) break;
          }
        }
        p = P[p][i];
      }
    }
  }
}
void process(int N) {
  int i, j, l, temp_size, cnt, now;
  for (i = 0; i < N; i++) {
    for (j = 0; 1 << j < N; j++) {
      P[i][j] = -1;
    }
  }
  for (i = 0; i < N; i++) {
    P[i][0] = T[i];
    now = P[i][0];
    temp_size = SOLD[now].size();
    cnt = 0;
    if (temp_size) {
      MSOLD[i][0].push_back(SOLD[now][0]);
      cnt++;
    }
    for (l = 1; l < temp_size; l++) {
      if (SOLD[now][l] != SOLD[now][l - 1]) {
        cnt++;
        MSOLD[i][0].push_back(SOLD[now][l]);
        if (cnt == 10) break;
      }
    }
  }
  for (j = 1; 1 << j < N; j++) {
    for (i = 0; i < N; i++) {
      if (P[i][j - 1] != -1) {
        TMP.clear();
        P[i][j] = P[P[i][j - 1]][j - 1];
        temp_size = MSOLD[i][j - 1].size();
        temp_size = min(temp_size, ten);
        for (l = 0; l < temp_size; l++) {
          TMP.push_back(MSOLD[i][j - 1][l]);
        }
        now = P[i][j - 1];
        temp_size = MSOLD[now][j - 1].size();
        temp_size = min(temp_size, ten);
        for (l = 0; l < temp_size; l++) {
          TMP.push_back(MSOLD[now][j - 1][l]);
        }
        sort(TMP.begin(), TMP.end());
        temp_size = TMP.size();
        cnt = 0;
        if (temp_size) {
          MSOLD[i][j].push_back(TMP[0]);
          cnt++;
        }
        for (l = 1; l < temp_size; l++) {
          if (TMP[l] != TMP[l - 1]) {
            cnt++;
            MSOLD[i][j].push_back(TMP[l]);
            if (cnt == ten) break;
          }
        }
      }
    }
  }
}
int main() {
  int i, j, k, test, cas, K, ans, Q, I, J, S, u, v, w, N, M, U, V, A, temp_size,
      cnt, l;
  cin >> N >> M >> Q;
  for (i = 1; i < N; i++) {
    scanf("%d%d", &u, &v);
    adj[u - 1].push_back(v - 1);
    adj[v - 1].push_back(u - 1);
  }
  for (i = 1; i <= M; i++) {
    scanf("%d", &j);
    SOLD[j - 1].push_back(i);
  }
  for (i = 0; i < N; i++) sort(SOLD[i].begin(), SOLD[i].end());
  for (i = 0; i < N; i++) {
    TMP.clear();
    TMP = SOLD[i];
    temp_size = TMP.size();
    SOLD[i].clear();
    cnt = 0;
    if (temp_size) {
      SOLD[i].push_back(TMP[0]);
      cnt++;
    }
    for (l = 1; l < temp_size; l++) {
      if (TMP[l] != TMP[l - 1]) {
        cnt++;
        SOLD[i].push_back(TMP[l]);
        if (cnt == ten) break;
      }
    }
  }
  bfs(0);
  process(N);
  while (Q--) {
    cin >> U >> V >> A;
    U--;
    V--;
    query(N, U, V);
    temp_size = ANS.size();
    temp_size = min(temp_size, A);
    printf("%d", temp_size);
    for (i = 0; i < temp_size; i++) printf(" %d", ANS[i]);
    printf("\n");
  }
  return 0;
}