#include <bits/stdc++.h>
using namespace std;
int N, M, K, D, cnt, A[100005], B[100005], C[100005], Q[100005], st[100005];
struct Lin {
  int v, next;
} E[100005 * 2];
bool V[100005];
void Link(int u, int v) {
  E[++D] = (Lin){v, st[u]};
  B[u]++;
  st[u] = D;
  E[++D] = (Lin){u, st[v]};
  B[v]++;
  st[v] = D;
}
bool check(double k) {
  for (int i = 1; i <= N; i++) V[i] = 1, C[i] = 0;
  for (int i = 1; i <= K; i++) V[A[i]] = 0;
  cnt = 0;
  for (int u = 1; u <= N; u++)
    if (V[u]) {
      for (int i = st[u]; i; i = E[i].next) C[u] += V[E[i].v];
      if (1. * C[u] / B[u] < k) Q[++cnt] = u;
    }
  for (int i = 1; i <= cnt; i++) V[Q[i]] = 0;
  for (int l = 0; l < cnt;) {
    int u = Q[++l];
    for (int i = st[u], v; i; i = E[i].next)
      if (V[v = E[i].v]) {
        if (1. * (--C[v]) / B[v] < k) Q[++cnt] = v, V[v] = 0;
      }
  }
  return cnt + K < N;
}
int main() {
  scanf("%d%d%d", &N, &M, &K);
  for (int i = 1; i <= K; i++) scanf("%d", &A[i]);
  for (int i = 1; i <= M; i++) {
    int u, v;
    scanf("%d%d", &u, &v);
    Link(u, v);
  }
  double l = 0, r = 1;
  for (; l + (1e-9) < r;) {
    double Mid = (l + r) * .5;
    check(Mid) ? l = Mid : r = Mid;
  }
  check(l);
  printf("%d\n", N - cnt - K);
  for (int i = 1; i <= N; i++)
    if (V[i]) printf("%d ", i);
}
