#include <bits/stdc++.h>
using namespace std;
vector<int> adj[200001];
int vis[200001], dis[200001], cnt[200001];
queue<int> q;
void bfs() {
  int v;
  while (!q.empty()) {
    v = q.front();
    q.pop();
    for (int u : adj[v]) {
      if (vis[u]) {
        if (dis[u] == dis[v] + 1) cnt[u]++;
        continue;
      }
      dis[u] = dis[v] + 1;
      vis[u] = 1;
      q.push(u);
    }
  }
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(nullptr);
  int n, m;
  cin >> n >> m;
  int u, v;
  for (int i = 0; i < m; i++) {
    cin >> u >> v;
    adj[v].push_back(u);
  }
  int k;
  cin >> k;
  int p[k];
  for (int i = 0; i < k; i++) cin >> p[i];
  memset(dis, 0, sizeof(dis));
  memset(cnt, 0, sizeof(cnt));
  memset(vis, 0, sizeof(vis));
  vis[p[k - 1]] = 1;
  q.push(p[k - 1]);
  bfs();
  int mx = 0, mn = 0;
  for (int i = 1; i < k; i++) {
    if (dis[p[i - 1]] != dis[p[i]] + 1)
      mn++;
    else if (cnt[p[i - 1]])
      mx++;
  }
  cout << mn << " " << mn + mx << "\n";
  return 0;
}
