#include <bits/stdc++.h>
using namespace std;
const int M = 200005;
set<int> nex[M];
int path[M];
int sh[M];
vector<int> edge[M];
int main() {
  int n, m;
  scanf("%d%d", &n, &m);
  for (int i = 0; i < m; i++) {
    int from, to;
    scanf("%d%d", &from, &to);
    edge[to].push_back(from);
  }
  for (int i = 1; i <= n; i++) {
    sh[i] = -1;
  }
  int k;
  scanf("%d", &k);
  for (int i = 1; i <= k; i++) {
    int p;
    scanf("%d", &p);
    path[i] = p;
  }
  queue<int> q;
  q.push(path[k]);
  sh[path[k]] = 0;
  int count = 1;
  while (!q.empty()) {
    int len = q.size();
    for (int i = 0; i < len; i++) {
      int x = q.front();
      q.pop();
      for (int v : edge[x]) {
        if (sh[v] == -1) {
          q.push(v);
          sh[v] = count;
          nex[v].insert(x);
        } else if (sh[v] == count) {
          nex[v].insert(x);
        }
      }
    }
    count++;
  }
  int mi = 0, ma = 0;
  for (int i = 1; i < k; i++) {
    if (nex[path[i]].find(path[i + 1]) == nex[path[i]].end()) {
      mi++;
      ma++;
    } else if (nex[path[i]].size() > 1) {
      ma++;
    }
  }
  printf("%d %d\n", mi, ma);
}
