#include <bits/stdc++.h>
using namespace std;
long long n, m, ans, z;
long long a[100005], f[100005];
int main() {
  cin >> n >> m;
  for (int i = 0; i < m; i++) {
    cin >> a[i];
    f[a[i]] = -1;
  }
  f[1] = 1;
  f[2] = 2;
  f[0] = 1;
  for (int i = 2; i <= n; i++) {
    if (f[i] == -1) {
      continue;
    }
    cout << "1" << endl;
    if (f[i - 1] == -1) {
      f[i] = f[i - 2];
    } else if (f[i - 2] == -1) {
      f[i] = f[i - 1];
    } else
      f[i] = f[i - 1] + f[i - 2];
  }
  cout << f[n];
}
