n,m = map(int,input().split())
a = list(int(input()) for i in range(m))
a.append(0)

dp = [0] * (n+1)
b = 0
for i in range(1,n+1):
    if a[b] == i:
        b += 1
    else:
        if i != 1 and i != 2:
            dp[i] = dp[i-1] + dp[i-2]
        else:
            if i == 1:
                dp[1] = 1
            elif i == 2 and a[0] == 1:
                dp[2] = 1
            else:
                dp[1] = 1
                dp[2] = 2
print(dp[-1] % (10 ** 9 + 7)) n,m = map(int,input().split()) n map(int,input().split()) map int input().split() ().split () input split m a = list(int(input()) for i in range(m)) a list(int(input()) for i in range(m)) list int(input()) int input() input a.append(0) a.append a append 0 dp = [0] * (n+1) dp [0] * (n+1) [0] 0 n+1 n 1 b = 0 b 0 for i in range(1,n+1):
    if a[b] == i:
        b += 1
    else:
        if i != 1 and i != 2:
            dp[i] = dp[i-1] + dp[i-2]
        else:
            if i == 1:
                dp[1] = 1
            elif i == 2 and a[0] == 1:
                dp[2] = 1
            else:
                dp[1] = 1
                dp[2] = 2 i range(1,n+1) range 1 n+1 n 1 if a[b] == i:
        b += 1
    else:
        if i != 1 and i != 2:
            dp[i] = dp[i-1] + dp[i-2]
        else:
            if i == 1:
                dp[1] = 1
            elif i == 2 and a[0] == 1:
                dp[2] = 1
            else:
                dp[1] = 1
                dp[2] = 2 a[b] == i a[b] a b i b += 1 b 1 if i != 1 and i != 2:
            dp[i] = dp[i-1] + dp[i-2]
        else:
            if i == 1:
                dp[1] = 1
            elif i == 2 and a[0] == 1:
                dp[2] = 1
            else:
                dp[1] = 1
                dp[2] = 2 i != 1 and i != 2 i != 1 i 1 i != 2 i 2 dp[i] = dp[i-1] + dp[i-2] dp[i] dp i dp[i-1] + dp[i-2] dp[i-1] dp i-1 i 1 dp[i-2] dp i-2 i 2 if i == 1:
                dp[1] = 1
            elif i == 2 and a[0] == 1:
                dp[2] = 1
            else:
                dp[1] = 1
                dp[2] = 2 i == 1 i 1 dp[1] = 1 dp[1] dp 1 1 elif i == 2 and a[0] == 1:
                dp[2] = 1
             i == 2 and a[0] == 1 i == 2 i 2 a[0] == 1 a[0] a 0 1 dp[2] = 1 dp[2] dp 2 1 dp[1] = 1 dp[1] dp 1 1 dp[2] = 2 dp[2] dp 2 2 print(dp[-1] % (10 ** 9 + 7)) print dp[-1] % (10 ** 9 + 7) dp[-1] dp -1 10 ** 9 + 7 10 ** 9 10 9 7 a = list(int(input()) for i in range(m)) list(int(input()) for i in range(m)) a dp = [0] * (n+1) [0] * (n+1) dp b = 0 0 b b += 1 1 b n,m = map(int,input().split()) map(int,input().split()) n m = map(int,input().split()) map(int,input().split()) m
n,m = map(int,input().split())
a = list(int(input()) for i in range(m))
a.append(0)

dp = [0] * (n+1)
b = 0
for i in range(1,n+1):
    if a[b] == i:
        b += 1
    else:
        if i != 1 and i != 2:
            dp[i] = dp[i-1] + dp[i-2]
        else:
            if i == 1:
                dp[1] = 1
            elif i == 2 and a[0] == 1:
                dp[2] = 1
            else:
                dp[1] = 1
                dp[2] = 2
print(dp[-1] % (10 ** 9 + 7))