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;
const int MAXn = 1000 * 100, MAXl = 20;
vector<int> adj[MAXn + 2], h[MAXn + 2][MAXl + 2];
bool mark[MAXn + 5];
int par[MAXn + 2][MAXl + 2], dis[MAXn + 5];
set<int> s[MAXn + 5], tmp;
void DFS(int v) {
  mark[v] = true;
  for (int i = 0; i < (int)adj[v].size(); i++)
    if (!mark[adj[v][i]]) {
      dis[adj[v][i]] = dis[v] + 1;
      par[adj[v][i]][0] = v;
      DFS(adj[v][i]);
    }
}
int get_par(int u, int d) {
  for (int i = MAXl - 1; i >= 0; i--)
    if (d >> i & 1) u = par[u][i];
  return u;
}
int LCA(int x, int y) {
  if (dis[x] < dis[y]) swap(x, y);
  x = get_par(x, dis[x] - dis[y]);
  if (x == y) return x;
  for (int i = MAXl - 1; i >= 0; i--)
    if (par[x][i] != par[y][i]) {
      x = par[x][i];
      y = par[y][i];
    }
  return par[x][0];
}
int main() {
  int n, m, q, lim = 10;
  scanf("%d%d%d", &n, &m, &q);
  for (int i = 0, u, v; i < n - 1; i++) {
    scanf("%d%d", &u, &v);
    u--;
    v--;
    adj[u].push_back(v);
    adj[v].push_back(u);
  }
  DFS(0);
  for (int j = 1; j < MAXl; j++)
    for (int i = 0; i < n; i++) par[i][j] = par[par[i][j - 1]][j - 1];
  for (int i = 0, c; i < m; i++) {
    scanf("%d", &c);
    c--;
    if (s[c].size() < lim) {
      s[c].insert(i);
    } else {
      if (*s[c].rbegin() > i) {
        s[c].insert(i);
        s[c].erase(*s[c].rbegin());
      }
    }
  }
  for (int i = 0; i < n; i++) {
    while (!s[i].empty()) {
      h[i][0].push_back(*s[i].begin());
      s[i].erase(s[i].begin());
    }
  }
  for (int j = 1; j < MAXl; j++)
    for (int i = 0; i < n; i++) {
      int u = par[i][j - 1], p = 0, t = 0;
      while (h[i][j].size() < lim &&
             (p < h[i][j - 1].size() || t < h[u][j - 1].size())) {
        if (p == h[i][j - 1].size()) {
          h[i][j].push_back(h[u][j - 1][t]);
          t++;
        } else {
          if (t == h[u][j - 1].size()) {
            h[i][j].push_back(h[i][j - 1][p]);
            p++;
          } else {
            if (h[i][j - 1][p] < h[u][j - 1][t]) {
              h[i][j].push_back(h[i][j - 1][p]);
              p++;
            } else {
              h[i][j].push_back(h[u][j - 1][t]);
              t++;
            }
          }
        }
      }
    }
  for (int i = 0, a; i < q; i++) {
    int u[2];
    scanf("%d%d%d", &u[0], &u[1], &a);
    u[0]--;
    u[1]--;
    int lca = LCA(u[0], u[1]);
    for (int j = 0; j < 2; j++) {
      int v = u[j];
      for (int k = MAXl - 1; k >= 0; k--)
        if ((dis[u[j]] - dis[lca] + j) >> k & 1) {
          for (int l = 0; l < (int)h[v][k].size(); l++)
            if (tmp.size() < a)
              tmp.insert(h[v][k][l]);
            else {
              if (*tmp.rbegin() > h[v][k][l]) {
                tmp.insert(h[v][k][l]);
                tmp.erase(*tmp.rbegin());
              }
            }
          v = par[v][k];
        }
    }
    printf("%d ", (int)tmp.size());
    while (!tmp.empty()) {
      printf("%d ", *tmp.begin() + 1);
      tmp.erase(tmp.begin());
    }
    printf("\n");
  }
  return 0;
}