import sys
sys.setrecursionlimit(10**6)

N, M = map(int, input().split())
inputs = [int(input()) for _ in range(M)]

mod = 10 ** 9 + 7
def dfs(count):
    if count in inputs or count > N:
        return 0
    if count == N:
        return 1
    return dfs(count+1) + dfs(count+2)

print(dfs(0) % mod)
