#include <bits/stdc++.h>
using namespace std;
void __print(int first) { cerr << first; }
void __print(long first) { cerr << first; }
void __print(long long first) { cerr << first; }
void __print(unsigned first) { cerr << first; }
void __print(unsigned long first) { cerr << first; }
void __print(unsigned long long first) { cerr << first; }
void __print(float first) { cerr << first; }
void __print(double first) { cerr << first; }
void __print(long double first) { cerr << first; }
void __print(char first) { cerr << '\'' << first << '\''; }
void __print(const char *first) { cerr << '\"' << first << '\"'; }
void __print(const string &first) { cerr << '\"' << first << '\"'; }
void __print(bool first) { cerr << (first ? "true" : "false"); }
template <typename T, typename V>
void __print(const pair<T, V> &first) {
  cerr << '{';
  __print(first.first);
  cerr << ',';
  __print(first.second);
  cerr << '}';
}
template <typename T>
void __print(const T &first) {
  int f = 0;
  cerr << '{';
  for (auto &i : first) cerr << (f++ ? "," : ""), __print(i);
  cerr << "}";
}
void _print() { cerr << "]\n"; }
template <typename T, typename... V>
void _print(T t, V... v) {
  __print(t);
  if (sizeof...(v)) cerr << ", ";
  _print(v...);
}
vector<vector<int> > vect;
vector<int> req_people[100010][25], city[100010];
int par[100010][25], hgt[100010];
inline void bfs(int parent, int node, int height) {
  par[node][0] = parent;
  for (auto &node1 : city[parent]) req_people[node][0].push_back(node1);
  hgt[node] = height;
  for (auto &child : vect[node]) {
    if (child != parent) {
      bfs(node, child, height + 1);
    }
  }
}
inline int LCA(int u, int v) {
  if (hgt[u] < hgt[v]) swap(u, v);
  int diff = abs(hgt[v] - hgt[u]);
  for (int j = 21; j >= 0; j--) {
    int temp = 1 << j;
    if (temp <= diff) {
      u = par[u][j];
      diff -= temp;
    }
  }
  for (int j = 21; j >= 0; j--) {
    if (par[u][j] != par[v][j]) {
      u = par[u][j];
      v = par[v][j];
    }
  }
  if (u == v)
    return u;
  else
    return par[u][0];
}
inline void fill_city(int i, int j) {
  for (auto &node : req_people[par[i][j - 1]][j - 1])
    req_people[i][j].push_back(node);
  for (auto &node : req_people[i][j - 1]) req_people[i][j].push_back(node);
  sort(req_people[i][j].begin(), req_people[i][j].end());
  while (req_people[i][j].size() > 10) req_people[i][j].pop_back();
}
inline void merge(vector<int> &a, vector<int> &b) {
  int cnt = 0, i = 0, j = 0;
  vector<int> temp;
  while (i < a.size() && j < b.size() && cnt <= 10) {
    if (a[i] < b[j])
      temp.push_back(a[i++]);
    else
      temp.push_back(b[j++]);
    cnt++;
  }
  while (i < a.size() && cnt <= 10) temp.push_back(a[i++]), cnt++;
  while (j < b.size() && cnt <= 10) temp.push_back(b[j++]), cnt++;
  a = temp;
}
inline void calc(int u, int v, vector<int> &ans, int add) {
  int diff = abs(hgt[v] - hgt[u]) - add;
  for (int j = 20; j >= 0; j--) {
    int temp = 1 << j;
    if (temp <= diff) {
      merge(ans, req_people[u][j]);
      u = par[u][j];
      diff -= temp;
    }
  }
}
int main() {
  ios::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  ;
  int n, m, q;
  cin >> n >> m >> q;
  vect.resize(n + 1);
  int node, u, v;
  for (int i = 1; i < n; i++) {
    cin >> u >> v;
    vect[u].push_back(v);
    vect[v].push_back(u);
  }
  for (int i = 1; i < m + 1; i++) {
    cin >> node;
    city[node].push_back(i);
  }
  bfs(0, 1, 1);
  for (int j = 1; j < 20; j++) {
    for (int i = 1; i < n + 1; i++) {
      par[i][j] = par[par[i][j - 1]][j - 1];
      fill_city(i, j);
    }
  }
  while (q--) {
    vector<int> ans;
    int u, v, a;
    cin >> u >> v >> a;
    if (hgt[u] > hgt[v]) swap(u, v);
    int lca = LCA(u, v);
    calc(u, lca, ans, 0);
    calc(v, lca, ans, 1);
    ;
    merge(ans, city[u]);
    if (u != v) merge(ans, city[v]);
    ;
    cout << min((int)ans.size(), a) << " ";
    for (int i = 0; i < min((int)ans.size(), a); i++) cout << ans[i] << " ";
    cout << "\n";
  }
}
