#include <bits/stdc++.h>
using namespace std;
int ans = 0;
int N, M;
vector<int> ma;
int dfs(int a) {
  if (find(ma.begin(), ma.end(), a) != ma.end()) {
    return 0;
  }
  if (a >= N) {
    ans++;
    ans = ans % 1000000007;
    return 0;
  }
  dfs(a + 1);
  if (a + 2 <= N) dfs(a + 2);
  return 0;
}
int main() {
  cin >> N >> M;
  for (int i = 0; i < M; i++) {
    int k;
    cin >> k;
    ma.push_back(k);
  }
  dfs(0);
  cout << ans << endl;
}
