def kaidan(i):
    global ans
    if ls.count(i+1)==0:
        if i+1==n:
            ans+=1
        else:
            kaidan(i+1)
    if ls.count(i+2)==0:
        if i+2==n:
            ans+=1
        elif i+2<n:
            kaidan(i+2)

k=0
ls=[]
ans=0

n,m=map(int,input().split())
for j in range(m):
    a=int(input())
    ls.append(a)

kaidan(0)
print(ans%1000000007)
