#include <bits/stdc++.h>
using namespace std;
template <class T>
inline T sqr(const T& a) {
  return a * a;
}
template <class T>
inline void updMin(T& a, const T& b) {
  if (b < a) a = b;
}
template <class T>
inline void updMax(T& a, const T& b) {
  if (b > a) a = b;
}
const int maxn = 100000 + 100;
const int maxk = 19;
const int A = 10;
vector<vector<int> > g;
vector<int> vis;
vector<int> tIn, tOut;
int timer = 0;
int pr[maxn][maxk];
vector<int> people[maxn][maxk];
vector<int> getMin(const vector<int>& a, const vector<int>& b) {
  vector<int> res(a.size() + b.size());
  int j = 0;
  for (int i = 0; i < a.size(); ++i) res[j++] = a[i];
  for (int i = 0; i < b.size(); ++i) res[j++] = b[i];
  sort(res.begin(), res.end());
  vector<int> res2;
  j = 0;
  for (int i = 0; i < res.size(); ++i) {
    if (i == 0 || res[i] != res[i - 1]) {
      res2.push_back(res[i]);
      ++j;
      if (j == A) break;
    }
  }
  return res2;
}
void dfs(int v, int p = 0) {
  vis[v] = true;
  tIn[v] = ++timer;
  pr[v][0] = p;
  for (int k = 1; k < maxk; ++k) {
    pr[v][k] = pr[pr[v][k - 1]][k - 1];
    people[v][k] = getMin(people[v][k - 1], people[pr[v][k - 1]][k - 1]);
  }
  int sz = g[v].size();
  for (int i = 0; i < sz; ++i) {
    int to = g[v][i];
    if (!vis[to]) dfs(to, v);
  }
  tOut[v] = ++timer;
}
bool inline isParent(int a, int b) {
  return tIn[a] <= tIn[b] && tOut[a] >= tOut[b];
}
int inline lca(int a, int b) {
  if (isParent(a, b)) return a;
  if (isParent(b, a)) return b;
  for (int k = maxk - 1; k >= 0; --k) {
    if (!isParent(pr[a][k], b)) a = pr[a][k];
  }
  return pr[a][0];
}
vector<int> pathMin(int v, int p) {
  if (v == p) return people[v][0];
  vector<int> res = people[v][0];
  for (int k = maxk - 1; k >= 0; --k) {
    if (!isParent(pr[v][k], p)) {
      res = getMin(people[v][k], pathMin(pr[v][k], p));
      return res;
    }
  }
  return getMin(res, people[pr[v][0]][0]);
}
int main() {
  int n, m, q;
  scanf("%d%d%d", &n, &m, &q);
  g.resize(n);
  for (int i = 0; i < n - 1; ++i) {
    int a, b;
    scanf("%d%d", &a, &b);
    --a;
    --b;
    g[a].push_back(b);
    g[b].push_back(a);
  }
  for (int i = 0; i < m; ++i) {
    int c;
    scanf("%d", &c);
    --c;
    people[c][0].push_back(i);
  }
  for (int i = 0; i < n; ++i) {
    sort(people[i][0].begin(), people[i][0].end());
    while (people[i][0].size() > A) people[i][0].pop_back();
  }
  vis.resize(n, 0);
  tIn.resize(n, 0);
  tOut.resize(n, 0);
  dfs(0);
  for (int i = 0; i < q; ++i) {
    int v, u, a;
    scanf("%d%d%d", &v, &u, &a);
    --v;
    --u;
    int t = lca(u, v);
    vector<int> res = getMin(pathMin(u, t), pathMin(v, t));
    if (res.size() < a) a = res.size();
    printf("%d ", a);
    for (int j = 0; j < a; ++j) printf("%d ", res[j] + 1);
    puts("");
  }
  return 0;
}
