#include <bits/stdc++.h>
using namespace std;
const int N = 2e5 + 5;
int n, m, k;
vector<int> g[N];
vector<int> path;
bool vis[N];
int dist[N], ways[N];
void solve() {
  cin >> n >> m;
  for (int i = 0, x, y; i < m; i++) {
    cin >> x >> y;
    g[y].push_back(x);
  }
  cin >> k;
  for (int i = 0, x; i < k; i++) {
    cin >> x;
    path.push_back(x);
  }
  queue<int> q;
  q.push(path[k - 1]);
  vis[path[k - 1]] = 1;
  while (!q.empty()) {
    int v = q.front();
    q.pop();
    for (int u : g[v]) {
      if (!vis[u]) {
        vis[u] = 1;
        dist[u] = dist[v] + 1;
        ways[u]++;
        q.push(u);
      } else if (vis[u] && dist[u] == dist[v] + 1) {
        ways[u]++;
      }
    }
  }
  int mn = 0, mx = 0;
  for (int i = 1; i < k; i++) {
    if (dist[path[i]] != (dist[path[i - 1]] - 1)) {
      mn++;
      mx++;
    } else if (ways[path[i - 1]] > 1) {
      mx++;
    }
  }
  cout << mn << " " << mx;
}
signed main() {
  ios::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  int t = 1;
  while (t--) {
    solve();
  }
  return 0;
}
