/*
#pragma GCC optimize(2)
#pragma GCC optimize(3,"Ofast","inline")
*/
#include<bits/stdc++.h>
#define ALL(x) (x).begin(),(x).end()
#define ll long long
#define db long double
#define ull unsigned long long
#define pii_ pair<int,int>
#define mp_ make_pair
#define pb push_back
#define fi first
#define se second
#define rep(i,a,b) for(int i=(a);i<=(b);i++)
#define per(i,a,b) for(int i=(a);i>=(b);i--)
#define show1(a) cout<<#a<<" = "<<a<<endl
#define show2(a,b) cout<<#a<<" = "<<a<<"; "<<#b<<" = "<<b<<endl
using namespace std;
const ll INF = 1LL<<60;
const int inf = 1<<30;
const int maxn = 2e5+5;
inline void fastio() {ios::sync_with_stdio(false);cin.tie(0);cout.tie(0);}

int flag[maxn];
db f1[maxn],f2[maxn],suf1[maxn],suf2[maxn];

int main()
{
    //fastio();
    int n,m,k; scanf("%d%d%d",&n,&m,&k);

    rep(i,1,k){
        int x; scanf("%d",&x);
        flag[x] = 1;
    }
    per(i,n-1,0){
        if(flag[i]){
            f1[i] = 0;f2[i] = 1;
        }else{
            f1[i] = 1.0 + (suf1[i+1] - suf1[i+m+1]) / m;
            f2[i] = (suf2[i+1] - suf2[i+m+1]) / m;
        }//show2(f1[i],f2[i]);
        suf1[i] = f1[i] + suf1[i+1];
        suf2[i] = f2[i] + suf2[i+1];
    }
    db ans = f1[0] / (1 - f2[0]);
    //printf("%.4Lf\n",ans);
    if(ans > 1e13) cout << -1 << endl;
    else cout << fixed << setprecision(4) << ans << endl;
    return 0;
}

#include <bits/stdc++.h>
using namespace std;
#define rep(i, a, b) for(int i = a; i < b; ++i)

int debug = 0;

const int N = 2e5, K = 18, inf = 1e9;
int n, m, k, ans, c[K], dp[K][1 << K], dist[K][K], d[N];
vector <int> g[N];

bool belong(int x, int mask) {
    return (mask >> x) & 1;
}

void bfs(int id) {
    int start = c[id];
    fill(d + 1, d + n + 1, -1);
    queue <int> q;
    q.push(start);
    d[start] = 0;
    while (!q.empty()) {
        int v = q.front();
        q.pop();
        for (int u : g[v]) {
            if (d[u] == -1) {
                d[u] = d[v] + 1;
                q.push(u);
            }
        }
    }
    rep(j, 0, k) {
        dist[id][j] = d[c[j]];
    }
}

void calcDist() {
    rep(i, 0, k) {
        bfs(i);
    }
}

main() {
    cin >> n >> m;
    rep(i, 0, m) {
        int u, v;
        cin >> u >> v;
        g[u].push_back(v);
        g[v].push_back(u);
    }
    cin >> k;
    rep(i, 0, k) fill(dp[i], dp[i] + (1 << k), inf);
    rep(i, 0, k) {
        cin >> c[i];
        dp[i][1 << i] = 1;
    }
    calcDist();
    rep(mask, 0, (1 << k)) {
        if ((int)__builtin_popcount(mask) > 1) {
            rep(v, 0, k) if (belong(v, mask)) {
                rep(u, 0, k) if (belong(u, mask) && u != v && dist[u][v] != -1) {
                    dp[v][mask] = min(dp[v][mask], dp[u][mask ^ (1 << v)] + dist[u][v]);
                }
            }
        }
    }
    ans = inf;
    rep(i, 0, k) {
        ans = min(ans, dp[i][(1 << k) - 1]);
    }
    if (ans == inf) ans = -1;
    cout << ans << '\n';
}