N, M = list(map(int, input().split()))
alist = []
for m in range(M) :
    alist.append(int(input()))
    
a2 = 0
a1 = 1
for n in range(N) :
    a0 = (a1 + a2)*int((n+1) not in alist)%1000000007
    print(a0)
    a2, a1 = a1, a0
else :
    print(a0)