import sys
input=sys.stdin.readline
n,m=map(int,input().split())
if m>0:
    a=[int(input()) for i in range(m)]

dp=[None]*(n+1)
dp[0]=1
for i in range(m):
    dp[a[i]]=0
if dp[1]==None:
    dp[1]=1

for i in range(2,n+1):
    if dp[i]==None:
        dp[i]=(dp[i-2]+dp[i-1])%1000000007

print(dp[-1]) import sys sys input=sys.stdin.readline input sys.stdin.readline sys.stdin sys stdin readline n,m=map(int,input().split()) n map(int,input().split()) map int input().split() ().split () input split m if m>0:
    a=[int(input()) for i in range(m)] m>0 m 0 int(input()) for i in range(m) for i in range(m) i range(m) range m for i in range(m) int(input()) int input() input a=[int(input()) for i in range(m)] a [int(input()) for i in range(m)] dp=[None]*(n+1) dp [None]*(n+1) [None] None n+1 n 1 dp[0]=1 dp[0] dp 0 1 for i in range(m):
    dp[a[i]]=0 i range(m) range m dp[a[i]]=0 dp[a[i]] dp a[i] a i 0 if dp[1]==None:
    dp[1]=1 dp[1]==None dp[1] dp 1 None dp[1]=1 dp[1] dp 1 1 for i in range(2,n+1):
    if dp[i]==None:
        dp[i]=(dp[i-2]+dp[i-1])%1000000007 i range(2,n+1) range 2 n+1 n 1 if dp[i]==None:
        dp[i]=(dp[i-2]+dp[i-1])%1000000007 dp[i]==None dp[i] dp i None dp[i]=(dp[i-2]+dp[i-1])%1000000007 dp[i] dp i (dp[i-2]+dp[i-1])%1000000007 dp[i-2]+dp[i-1] dp[i-2] dp i-2 i 2 dp[i-1] dp i-1 i 1 1000000007 print(dp[-1]) print dp[-1] dp -1 input=sys.stdin.readline sys.stdin.readline input m=map(int,input().split()) map(int,input().split()) m dp=[None]*(n+1) [None]*(n+1) dp n,m=map(int,input().split()) map(int,input().split()) n a=[int(input()) for i in range(m)] [int(input()) for i in range(m)] a
import sys
input=sys.stdin.readline
n,m=map(int,input().split())
if m>0:
    a=[int(input()) for i in range(m)]

dp=[None]*(n+1)
dp[0]=1
for i in range(m):
    dp[a[i]]=0
if dp[1]==None:
    dp[1]=1

for i in range(2,n+1):
    if dp[i]==None:
        dp[i]=(dp[i-2]+dp[i-1])%1000000007

print(dp[-1])