#include <bits/stdc++.h>
#pragma GCC optimize("O3")
#pragma GCC optimize("Ofast")
#pragma GCC target("sse4.2")
using namespace std;
const long long maxn = 1e6;
long long n, m, k, t;
vector<long long> V1[maxn];
vector<long long> V[maxn];
long long D[maxn];
int main() {
  ios_base ::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  ;
  long long q, w, e, a, b;
  cin >> n >> m;
  for (q = 0; q < m; q++) {
    cin >> a >> b;
    a--;
    b--;
    V[b].push_back(a);
    V1[a].push_back(b);
  }
  cin >> k;
  vector<long long> P;
  for (q = 0; q < k; q++) {
    cin >> a;
    a--;
    P.push_back(a);
  }
  long long ans1 = 0, ans2 = 0;
  for (q = 0; q < n; q++) {
    D[q] = -1;
  }
  D[P.back()] = 0;
  queue<long long> Q;
  Q.push(P.back());
  while (!Q.empty()) {
    long long v = Q.front();
    Q.pop();
    for (auto v1 : V[v]) {
      if (D[v1] != -1) {
        continue;
      }
      D[v1] = D[v] + 1;
      Q.push(v1);
    }
  }
  for (q = 0; q + 1 < P.size(); q++) {
    if (D[P[q + 1]] != D[P[q]] - 1) {
      ans1++;
      ans2++;
    } else {
      bool f = 0;
      long long v = P[q];
      for (auto v1 : V1[v]) {
        if (D[v1] == D[v] - 1 && v1 != P[q + 1]) {
          f = 1;
        }
      }
      if (f) {
        ans2++;
      }
    }
  }
  cout << ans1 << " " << ans2;
  return 0;
}
