a=open(0)
N,_,*a = map(int, a.read().split())

l,m = [0,0]
for i in range(1, N+1):
    if i in a:
        l,m = m,0
    elif i<3:
        l,m = m,m+1
    else:
        l,m = m,(l+m)%1000000007
print(m)

