#include <bits/stdc++.h>
using namespace std;
int N, M, Q;
vector<int> adj[(100000 + 100)];
vector<int> city[(100000 + 100)];
int jads[(100000 + 100)][22];
int LOG;
int level[(100000 + 100)];
vector<int> peoples[(100000 + 100)][22];
vector<int> MERGE(vector<int> &a, vector<int> &b, int A = 10) {
  vector<int> v(min(A, ((int)(a).size()) + ((int)(b).size())));
  int it1 = 0, it2 = 0, it3 = 0;
  while (it3 < ((int)(v).size()) &&
         (it1 < ((int)(a).size()) || it2 < ((int)(b).size()))) {
    if (it2 >= ((int)(b).size()) || it1 < ((int)(a).size()) && a[it1] < b[it2])
      v[it3++] = a[it1++];
    else
      v[it3++] = b[it2++];
  }
  return v;
}
void go(int u, int papa, int cur_level) {
  jads[u][0] = papa;
  level[u] = cur_level;
  for (int v : adj[u])
    if (v != papa) {
      go(v, u, cur_level + 1);
    }
}
void preCalc() {
  memset(jads, -1, sizeof jads);
  go(0, -1, 0);
  for (LOG = 1; (1 << LOG) <= N; LOG++) {
    for (int i = 0; i < N; i++) {
      if (jads[i][LOG - 1] != -1) {
        jads[i][LOG] = jads[jads[i][LOG - 1]][LOG - 1];
        vector<int> &a = peoples[i][LOG - 1];
        vector<int> &b = peoples[jads[i][LOG - 1]][LOG - 1];
        vector<int> &v = peoples[i][LOG];
        v = MERGE(a, b);
      }
    }
  }
}
vector<int> getPeople(int u, int v, int a) {
  if (level[u] > level[v]) swap(u, v);
  int d_level = level[v] - level[u];
  vector<int> V;
  for (int T = LOG - 1; T >= 0 && d_level; T--) {
    if (d_level >> T & 1) {
      V = MERGE(V, peoples[v][T], a);
      v = jads[v][T];
      d_level -= 1 << T;
    }
  }
  if (u == v) {
    V = MERGE(V, peoples[u][0], a);
    return V;
  }
  for (int T = LOG - 1; T >= 0; T--) {
    if (jads[u][T] != jads[v][T]) {
      V = MERGE(V, peoples[u][T], a);
      V = MERGE(V, peoples[v][T], a);
      u = jads[u][T];
      v = jads[v][T];
    }
  }
  V = MERGE(V, peoples[u][0], a);
  V = MERGE(V, peoples[v][0], a);
  V = MERGE(V, peoples[jads[u][0]][0], a);
  return V;
}
int main() {
  scanf("%d %d %d", &N, &M, &Q);
  for (int i = 0; i < N - 1; i++) {
    int u, v;
    scanf("%d %d", &u, &v);
    u--;
    v--;
    adj[u].push_back(v);
    adj[v].push_back(u);
  }
  for (int i = 0; i < M; i++) {
    int t;
    scanf("%d", &t);
    peoples[t - 1][0].push_back(i + 1);
  }
  preCalc();
  for (int i = 0; i < Q; i++) {
    int u, v, a;
    scanf("%d %d %d", &u, &v, &a);
    u--;
    v--;
    vector<int> V = getPeople(u, v, a);
    int k = min(((int)(V).size()), a);
    printf("%d", k);
    for (int i = 0; i < k; i++) printf(" %d", V[i]);
    printf("\n");
  }
  return 0;
}
