#include <bits/stdc++.h>
using namespace std;
const int nmax = int(2e5) + 5;
int n, m, a[nmax], d[nmax], minCnt, maxCnt;
bool check[nmax];
vector<int> c[nmax];
queue<int> qu;
void input() {
  int p, q;
  scanf("%d%d", &n, &m);
  while (m--) {
    scanf("%d%d", &p, &q);
    c[q].push_back(p);
  }
  scanf("%d", &m);
  for (int i = 1; i <= m; ++i) scanf("%d", &a[i]);
}
void bfs() {
  int k;
  memset(d, -1, sizeof(d));
  d[a[m]] = 0;
  qu.push(a[m]);
  while (!qu.empty()) {
    k = qu.front();
    qu.pop();
    for (const auto& it : c[k]) {
      if (d[it] == -1) {
        d[it] = d[k] + 1;
        qu.push(it);
      } else if (d[it] == d[k] + 1) {
        check[it] = true;
      }
    }
  }
  for (int i = 1; i < m; ++i) {
    int p = a[i], q = a[i + 1];
    if (d[p] != d[q] + 1) {
      ++minCnt;
      ++maxCnt;
    } else {
      if (check[p]) ++maxCnt;
    }
  }
  printf("%d %d\n", minCnt, maxCnt);
}
int main() {
  input();
  bfs();
  return 0;
}
