#include <bits/stdc++.h>
using namespace std;
int const N = 200009;
vector<int> adj[N];
bool was[N];
int d[N];
int f[N];
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  int n, m;
  cin >> n >> m;
  for (int i = 0; i < m; i++) {
    int u, v;
    cin >> u >> v;
    adj[v].push_back(u);
  }
  int k;
  cin >> k;
  int a[k];
  for (int i = 0; i < k; i++) cin >> a[i];
  queue<int> q;
  q.push(a[k - 1]);
  was[a[k - 1]] = 1;
  while (!q.empty()) {
    int v = q.front();
    q.pop();
    for (int u : adj[v]) {
      if (!was[u]) {
        d[u] = d[v] + 1;
        was[u] = 1;
        q.push(u);
      }
    }
  }
  memset(was, false, sizeof(was));
  was[a[k - 1]] = 1;
  q.push(a[k - 1]);
  f[a[k - 1]] = 1;
  while (!q.empty()) {
    int v = q.front();
    q.pop();
    for (int u : adj[v]) {
      if (d[u] == d[v] + 1) f[u] += f[v];
      if (!was[u]) {
        was[u] = 1;
        q.push(u);
      }
    }
  }
  int mn = 0, mx = 0;
  int cura = d[a[0]];
  int curb = f[a[0]];
  for (int i = 1; i < k; i++) {
    if (d[a[i]] != cura - 1) {
      mn++;
      cura = d[a[i]];
      mx++;
      curb = f[a[i]];
    } else {
      cura--;
      if (curb != f[a[i]]) {
        curb = f[a[i]];
        mx++;
      }
    }
  }
  cout << mn << " " << mx << endl;
  return 0;
}
