n,m = list(map(int,input().split()))

l = [1]*(n+1)

#kubaru_dp = [1]*n



for i in range(m):

    a = int(eval(input()))

    l[a] = 0



# l = [1,1,1,0,1,1,1]

for i in range(2,n+1):

    if l[i]==0:

        continue

    l[i] = l[i-1]+l[i-2]

else:

    print((l[-1]%(10**9+7)))

n,m = list(map(int,input().split()))

l = [1]*(n+1)

#kubaru_dp = [1]*n



for i in range(m):

    a = int(eval(input()))

    l[a] = 0



# l = [1,1,1,0,1,1,1]

for i in range(2,n+1):

    if l[i]==0:

        continue

    l[i] = (l[i-1]+l[i-2])%(10**9+7)

else:

    print((l[-1]%(10**9+7)))

n, m = list(map(int, input().split()))
l = [1] * (n + 1)
# kubaru_dp = [1]*n
for i in range(m):
    a = int(eval(input()))
    l[a] = 0
# l = [1,1,1,0,1,1,1]
for i in range(2, n + 1):
    if l[i] == 0:
        continue
    l[i] = l[i - 1] + l[i - 2]
else:
    print((l[-1] % (10**9 + 7)))

n, m = list(map(int, input().split()))
l = [1] * (n + 1)
# kubaru_dp = [1]*n
for i in range(m):
    a = int(eval(input()))
    l[a] = 0
# l = [1,1,1,0,1,1,1]
for i in range(2, n + 1):
    if l[i] == 0:
        continue
    l[i] = (l[i - 1] + l[i - 2]) % (10**9 + 7)
else:
    print((l[-1] % (10**9 + 7)))

-    l[i] = l[i - 1] + l[i - 2] +    l[i] = (l[i - 1] + l[i - 2]) % (10**9 + 7)