CodeEff/ECCO huggingface dataset:
# Original solution
# coding: utf-8
# Your code here!
import sys

def input():
    return sys.stdin.readline().strip()

N, M = list(map(int, input().split()))
a = [int(eval(input())) for _ in range(M)]
li = [1] + [0 for _ in range(N)]

for i in range(1, N + 1):
    if i in a:
        continue
    else:
        li[i] = li[i - 1] + li[i - 2]
print((li[-1] % 1000000007))

# Optimized solution
# coding: utf-8
# Your code here!
import sys

def input():
    return sys.stdin.readline().strip()

N, M = list(map(int, input().split()))
a = set(int(eval(input())) for _ in range(M))
li = [1] + [0 for _ in range(N)]

for i in range(1, N + 1):
    if i in a:
        continue
    else:
        li[i] = li[i - 1] + li[i - 2]
print((li[-1] % 1000000007))
# Original solution
mod = 10**9+7
n,m = list(map(int,input().split()))
lst = [int(eval(input())) for _ in range(m)]
dp = [0]*(n+1)
for i in range(1,n+1):
    if i in lst:
        continue
    elif i==1:
        dp[i] = 1
    elif i==2:
        dp[i] = dp[1]+1
    else:
        dp[i] = (dp[i-1] + dp[i-2])%mod
print((dp[n]))

# Optimized solution
mod = 10**9+7
n,m = list(map(int,input().split()))

dp = [0]*(n+2)
dp[0] = 1

for i in range(m):
    dp[int(eval(input()))] = -1

for i in range(n):
    if dp[i] != -1:
        if dp[i+1] != -1:
            dp[i+1] += dp[i]
        if dp[i+2] != -1:
            dp[i+2] += dp[i]

print((dp[n]%mod))
# Original solution
#coding utf-8
N,M=list(map(int,input().split()))
a =[int(eval(input())) for i in range(M)]
mod =10**9+7
dp = [1]
for i in range(1,N+1):
  if i not in a:
    if i ==1:
      dp.append(dp[-1])
    else:
      dp.append((dp[-1]+dp[-2])%mod)
  else:
    dp.append(0)

print((dp[-1]))

# Optimized solution
#coding utf-8
N,M=list(map(int,input().split()))
a =[int(eval(input())) for i in range(M)]
a.append(0)
mod =10**9+7
dp = [1]
j = 0
for i in range(1,N+1):
  if i != a[j]:
    if i ==1:
      dp.append(dp[-1])
    else:
      dp.append((dp[-1]+dp[-2])%mod)
  else:
    dp.append(0)
    j +=1 

print((dp[-1]))
# Original solution
n, m = list(map(int, input().split(' ')))

bads = []
for i in range(m):
    bads.append(int(eval(input())))

dp = [1, 1]
for i in range(2, n+1):
    dp.append(0)
    if i-1 not in bads:
        dp[i] += dp[i-1]
    if i-2 not in bads:
        dp[i] += dp[i-2]
    dp[i] %= 1000000007

print((dp[-1]))


# Optimized solution
n, m = list(map(int, input().split(' ')))

bads = {}
for i in range(m):
    bads[int(eval(input()))] = None

dp = [1]
if 1 not in bads:
    dp.append(1)
else:
    dp.append(0)
for i in range(2, n+1):
    dp.append(0)
    if i-1 not in bads:
        dp[i] += dp[i-1]
    if i-2 not in bads:
        dp[i] += dp[i-2]
    dp[i] %= 1000000007

print((dp[-1]))
# Original solution
n,m = list(map(int,input().split()))
a = [int(eval(input())) for i in range(m)]

cnt2 = 0
cnt1 = 1

for i in range(1,n):
    if i in a:
        cnt2, cnt1 = cnt1, 0
    else:
        cnt2, cnt1 = cnt1, cnt2+cnt1
else:
    ans = (cnt2+cnt1)%1000000007

print(ans)


# Optimized solution
n,m = list(map(int,input().split()))
aa = [int(eval(input())) for i in range(m)]

cnt2 = 0
cnt1 = 1
aa.append(-1)
a = aa.pop(0)


for i in range(1,n):
    if i == a:
        cnt2, cnt1 = cnt1, 0
        a = aa.pop(0)
    else:
        cnt2, cnt1 = cnt1, cnt2+cnt1
else:
    ans = (cnt2+cnt1)%1000000007

print(ans)
# Original solution
n,m = list(map(int,input().split()))
aa = [int(eval(input())) for i in range(m)]

cnt2 = 0
cnt1 = 1
aa.append(-1)
a = aa.pop(0)


for i in range(1,n):
    if i == a:
        cnt2, cnt1 = cnt1, 0
        a = aa.pop(0)
    else:
        cnt2, cnt1 = cnt1, cnt2+cnt1
else:
    ans = (cnt2+cnt1)%1000000007

print(ans)

# Optimized solution
n,m = list(map(int,input().split()))
a = [int(eval(input())) for _ in range(m)]
a.append(-1)
idx = 0
mod = 10**9+7
dp = [0]*(n+1)

dp[0] = 1
if a[idx] == 1: idx += 1
else: dp[1] = 1

for i in range(2,n+1):
    if i == a[idx]:
        dp[i] = 0
        idx += 1
    else:
        dp[i] = (dp[i-1] + dp[i-2])%mod
        
print((dp[n]))
# Original solution
n, m = list(map(int, input().split()))
mod = 10 ** 9 + 7
a = []
for i in range(m):
    a.append(int(eval(input())))

pat = [1]
zero = False
for i in range(1, n + 1):
    if i - 1 in a and i - 2 in a:
        zero = True
        break
    if i in a:
        pat.append(0)
        continue
    cnt = 0
    if i - 1 not in a:
        cnt = (cnt + pat[i - 1]) % mod
    if i - 2 >= 0 and i - 2 not in a:
        cnt = (cnt + pat[i - 2]) % mod
    pat.append(cnt)

if zero:
    print((0))
else:
    print((pat[n]))


# Optimized solution
n, m = list(map(int, input().split()))
mod = 10 ** 9 + 7
pat = [0] * (n + 2)
pat[0] = 1
pat[1] = 1

for i in range(m):
    a = int(eval(input()))
    pat[a] = -1

for i in range(2, n + 1):
    if pat[i] < 0:
        continue
    if pat[i - 1] > 0:
        pat[i] = (pat[i] + pat[i - 1]) % mod
    if pat[i - 2] > 0:
        pat[i] = (pat[i] + pat[i - 2]) % mod

print((pat[n]))
# Original solution
n, m = list(map(int, input().split()))
A = []
for i in range(m):
    A.append(int(eval(input())))
    
dp = [0 for i in range(n + 1)]
dp[0] = 1

for i in range(n+1):
    if not i in A:
        if i >= 2:
            dp[i] += (dp[i-2] + dp[i-1]) % (10 ** 9 + 7)
        elif i == 1:
            dp[i] += dp[i-1] % (10 ** 9 + 7)
    else:
        A.remove(i)
        
print((dp[-1] % (10 ** 9 + 7)))

# Optimized solution
n, m = list(map(int, input().split()))
mod = 10 ** 9 + 7
A = []
for i in range(m):
    A.append(int(eval(input())))
    
dp = [None for i in range(n + 1)]
dp[0] = 1

for a in A:
    dp[a] = 0
    
for i in range(1,n+1):
    if dp[i] != 0:
        dp[i] = 0
        if i >= 2:
            dp[i] += (dp[i-2] + dp[i-1]) % mod
        elif i == 1:
            dp[i] += dp[i-1] % mod
            
print((dp[-1]))
# Original solution
n, m = list(map(int, input().split()))
a = tuple(map(int, [eval(input()) for _ in range(m)]))

dp = [0] * (n+1)
# 0段目と1段目は1通り（但し、１段目が壊れていない場合）（0 段目は「なにもしない」という から1 通り）
dp[:2] = 1, 1 if 1 not in a else 0 

for i in range(2, n+1):
    if i in a:
        continue
    else:
        dp[i] = (dp[i-1] + dp[i-2])

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


# Optimized solution
n, m = list(map(int, input().split()))
a = set(map(int, [eval(input()) for _ in range(m)]))

dp = [0] * (n+1)
# 0段目と1段目は1通り（但し、１段目が壊れていない場合）（0 段目は「なにもしない」という から1 通り）
dp[:2] = 1, 1 if 1 not in a else 0 

for i in range(2, n+1):
    if i in a:
        continue
    else:
        dp[i] = (dp[i-1] + dp[i-2])

print((dp[-1] % (10**9+7)))
# Original solution
n, m = list(map(int, input().split()))
a = set(map(int, [eval(input()) for _ in range(m)]))

dp = [0] * (n+1)
# 0段目と1段目は1通り（但し、１段目が壊れていない場合）（0 段目は「なにもしない」という から1 通り）
dp[:2] = 1, 1 if 1 not in a else 0 

for i in range(2, n+1):
    if i in a:
        continue
    else:
        dp[i] = (dp[i-1] + dp[i-2])

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


# Optimized solution
import sys
input = sys.stdin.readline

n, m = list(map(int, input().split()))
broken_steps = set([int(eval(input())) for _ in range(m)])
#print(broken_steps)

def ptn_num(x): # 'x'stepまでのパターン数
    if x == 1:
        print((1))
    else:
        dp = [0] * (x+1) # DP枠_including step'0'
        cnt = 0
        if 1 in broken_steps: # in case, step'1' broken 
            dp[:2] = 1, 0
        else:
            dp[:2] = 1, 1 # Usually

        for i in range(2, x+1):
            if i in broken_steps: # 階段が壊れている場合...
                cnt += 1
                if cnt == 2:
                    print((0))
                    exit()
            else: # 階段が壊れてない場合...
                dp[i] = (dp[i-1] + dp[i-2]) % (10**9+7)
                cnt = 0
        
        print((dp[-1]))

ptn_num(n)
# Original solution
import sys
input = sys.stdin.readline

n, m = list(map(int, input().split()))
broken_steps = [int(eval(input())) for _ in range(m)]
#print(broken_steps)

def ptn_num(x): # 'x'stepまでのパターン数
    if x == 1:
        print((1))
    else:
        dp = [0] * (x+1) # DP枠_including step'0'
        cnt = 0
        if 1 in broken_steps: # in case, step'1' broken 
            dp[:2] = 1, 0
        else:
            dp[:2] = 1, 1 # Usually

        for i in range(2, x+1):
            if i in broken_steps: # 階段が壊れている場合...
                cnt += 1
                if cnt == 2:
                    print((0))
                    exit()
            else: # 階段が壊れてない場合...
                dp[i] = (dp[i-1] + dp[i-2]) % (10**9+7)
                cnt = 0
        
        print((dp[-1]))

ptn_num(n)


# Optimized solution
import sys
input = sys.stdin.readline

n, m = list(map(int, input().split()))
broken = set([int(eval(input())) for _ in range(m)]) # ここが'list'だとPypyでも通らない
#print(broken_steps)

def ptn_num(x): # 'x'stepまでのパターン数
    if x == 1:
        print((1))
    else:
        dp = [0] * (x+1) # DP枠_including step'0'
        cnt = 0 # 連続して壊れている階段を記録, '2'でゴール不可
        if 1 in broken: # in case, step'1' broken 
            dp[:2] = 1, 0
        else:
            dp[:2] = 1, 1 # Usually

        for i in range(2, x+1):
            if i in broken: # 階段が壊れている場合...
                cnt += 1
                if cnt == 2: # 2段連続壊れている場合は...
                    print((0))
                    exit()
            else: # 階段が壊れてない場合...
                dp[i] = (dp[i-1] + dp[i-2]) % (10**9+7)
                cnt = 0
        
        print((dp[-1]))

ptn_num(n)
# Original solution
n, m = list(map(int, input().split()))
a = set(map(int, [eval(input()) for _ in range(m)]))

dp = [0] * (n+1)
# 0段目と1段目は1通り（但し、１段目が壊れていない場合）（0 段目は「なにもしない」という から1 通り）
dp[:2] = 1, 1 if 1 not in a else 0 

for i in range(2, n+1):
    if i not in a:
        dp[i] = (dp[i-1] + dp[i-2])

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


# Optimized solution
n, m = list(map(int, input().split()))
a = set(map(int, [eval(input()) for _ in range(m)]))

dp = [0] * (n+1)
# 0段目と1段目は1通り（但し、１段目が壊れていない場合）（0 段目は「なにもしない」という から1 通り）
dp[:2] = 1, 1 if 1 not in a else 0 

for i in range(2, n+1):
    if i not in a:
        dp[i] = ((dp[i-1] + dp[i-2]) % (10**9+7))

print((dp[-1]))
# Original solution
import sys
input = sys.stdin.readline

n, m = list(map(int, input().split()))
broken = set([int(eval(input())) for _ in range(m)]) # ここが'list'だとPypyでも通らない

def ptn_num(x): # 'x'stepまでのパターン数
    dp = [0] * (x+1) # DP枠_including step'0'
    if 1 in broken: # in case, step'1' broken 
        dp[:2] = 1, 0
    else:
        dp[:2] = 1, 1 # Usually

    for i in range(2, x+1):
        if i not in broken: # 階段が壊れてない場合...
            dp[i] = (dp[i-1] + dp[i-2]) % (10**9+7) # -1段目と-2段目の合計
    print((dp[-1]))

ptn_num(n)


# Optimized solution
import sys
input = sys.stdin.readline

n, m = list(map(int, input().split()))
broken = set([int(eval(input())) for _ in range(m)]) # ここが'list'だとPypyでも通らない

def ptn_num(x): # 'x'stepまでのパターン数
    dp = [0] * (x+1) # DP枠_including step'0'
    if 1 in broken: # 固定部分_in case, step'1' broken 
        dp[:2] = 1, 0
    else:
        dp[:2] = 1, 1 # 固定部分_Usually

    for i in range(2, x+1):
        if i not in broken: # 階段が壊れてない場合...
            dp[i] = (dp[i-1] + dp[i-2]) % (10**9+7) # -1段目と-2段目の合計
    print((dp[-1]))

ptn_num(n)
# Original solution
from sys import exit

N, M = list(map(int, input().split()))

_a = -1
A = []
ans = 0

for _ in range(M):
    a_ = int(eval(input()))
    if _a + 1 == a_:
        print((0))
        exit()
    _a = a_
    A.append(_a)

step = [0] * (N + 1)

step[0] = 1

for s in range(1, N + 1):
    if s in A:
        step[s] = 0
        continue
    if s == 1:
        step[s] = 1
        continue
    else:
        step[s] = (step[s - 1] + step[s - 2]) % 1000000007

print((step[N]))


# Optimized solution
N, M = list(map(int, input().split()))

A = [False] * (N + 1)

for _ in range(M):
    A[int(eval(input()))] = True

step = [0] * (N + 1)

step[0] = 1

for s in range(1, N + 1):
    if A[s]:
        step[s] = 0
        continue
    if s == 1:
        step[s] = 1
        continue
    else:
        step[s] = step[s - 1] + step[s - 2]
        step[s] %= 1000000007

print((step[N]))
# Original solution
# coding: utf-8
import sys
input = sys.stdin.readline
N,M=list(map(int,input().split()))
A=[0]*M
for i in range(M):
    A[i]=int(eval(input()))
#print(A)
def dp(n):
    dp=[0]*(N+1)
    dp[0]=1
    dp[1]=0 if 1 in A else 1
    for i in range(N-1):
        if (i+2) in A:
            dp[i+2]=0
        else:
            dp[i+2]=dp[i+1]+dp[i]
    return dp[n]
print((dp(N)%(10**9+7)))

# Optimized solution
# coding: utf-8
import sys
input = sys.stdin.readline
N,M=list(map(int,input().split()))
A=[0]*M
dp=[-1]*(N+1)
for i in range(M):
    tmp=int(eval(input()))
    dp[tmp]=0
#print(dp)
dp[0]=1
dp[1]=0 if dp[1]==0 else 1

for i in range(2,N+1):
    if dp[i]!=0:
        dp[i]=dp[i-1]+dp[i-2]
        
print((dp[N]%(10**9+7)))
# Original solution
import math

def move(n):
	twonum = n // 2
	com = 0
	for i in range(twonum + 1):
		up = n - i
		com += math.factorial(up) // (math.factorial(up - i) * math.factorial(i))
	return com

N, M = list(map(int, input().split()))
a = []
a.append(0)
for i in range(M):
	a.append(int(eval(input())))
a.append(N+1)

s = 1
for i in range(M+1):
	step = a[i+1] - a[i] - 1
	m = move(step)
	s = s * m
	a[i+1] += 1

print((s % 1000000007))


# Optimized solution
N, M = list(map(int, input().split()))
a = []
for i in range(M):
	a.append(int(eval(input())))
a.append(-1)

m = []
for i in range(N):
	if i == a[0] - 1:
		del a[0]
		m.append(0)
	elif i == 0:
		m.append(1)
	elif i == 1:
		m.append(m[0]+1)
	else:
		m.append(m[i-1]+m[i-2])

print((m[N-1] % 1000000007))
# Original solution
N, M=list(map(int, input().split()))
items=[int(eval(input())) for i in range(M)]
mod=10**9+7
dp=[0 for i in range(N+1)]
dp[0] = 1
is_broken =[1 for i in range(N+1)]

for i in range(M):
    is_broken[items[i]] = 0

for i in range(N):
    if i-1 >= 0:
        dp[i+1] = dp[i]*is_broken[i] + dp[i-1]*is_broken[i-1]
    else:
        dp[i+1] = dp[i]*is_broken[i]
    dp[i+1] %= mod

print((dp[N]))

# Optimized solution
N, M=list(map(int, input().split()))
mod=10**9+7
dp=[0 for i in range(N+2)]
dp[N] = 1
is_broken =[False for i in range(N+1)]

for i in range(M):
    a=int(eval(input()))
    is_broken[a] = True

for i in reversed(list(range(N))):
    if is_broken[i]:
        dp[i] = 0
        continue
    dp[i] = (dp[i+1] + dp[i+2]) % mod

print((dp[0]))
# Original solution
N, M= list(map(int, input().split()))
a =[str(eval(input())) for _ in range(M)]
DP = [0]*(N+2)
num = 1000000007
DP[0] = 1
for i in range(N):
  if str(i) in a:
    DP[i] = 0
  else:
    DP[i] = DP[i] % num 
    if i < N:
      DP[i+1] += DP[i]
      DP[i+2] += DP[i]
print((DP[-2]%num))


# Optimized solution
N, M, = list(map(int, input().split()))
a = set([int(eval(input())) for _ in range(M)])
DP = [0]*(N+2)
num = 1000000007
DP[0] = 1
for i in range(N):
  if i in a:
    DP[i] = 0
  else:
    DP[i] = DP[i] % num 
    if i < N:
      DP[i+1] += DP[i]
      DP[i+2] += DP[i]
print((DP[-2]%num))
# Original solution
N, M = list(map(int, input().split()))
broken_lst = []
for _ in range(M):
    broken_lst.append(int(eval(input())))

counter_arr = [0]*(N+1)

counter_arr[0] = 1
next_broken = -1
if len(broken_lst) != 0:
    next_broken = broken_lst.pop(0)
last_broken = -1

for i in range(0, N-1):
    flug = 0
    if i+1 == next_broken:
        flug = 1
#        print("p0", i, counter_arr)
    elif i+1 == last_broken:
        pass
#        print("p1",i, counter_arr)
    else:
        counter_arr[i+1] += counter_arr[i]
        counter_arr[i+1] %= 10**9 + 7
#        print("p2",i,  counter_arr)

    if i + 2 == next_broken:
        flug = 1
#        print("p3",i, counter_arr)
    else:
        if i == 0 and len(broken_lst) != 0:
            if broken_lst[0] == 2 and next_broken == 1:
                continue
        counter_arr[i+2] += counter_arr[i]
        counter_arr[i+2] %= 10**9 + 7
#        print("p4",i, counter_arr)
    
    if flug == 1:
        last_broken = next_broken
        if len(broken_lst) != 0:
            next_broken = broken_lst.pop(0)

if last_broken != N - 1:
    counter_arr[-1] += counter_arr[-2]
counter_arr[-1] %= 10**9 + 7

print((counter_arr[-1]))


# Optimized solution
N, M = list(map(int, input().split()))
broken_lst = [1]*(N+1)
for _ in range(M):
    broken_lst[int(eval(input()))] = 0

counter_arr = [0]*(N+1)
counter_arr[0] = 1


for i in range(0, N-1):
    counter_arr[i+1] += counter_arr[i] * broken_lst[i+1]
    counter_arr[i+1] %= 10**9 + 7
    counter_arr[i+2] += counter_arr[i] * broken_lst[i+2]
    counter_arr[i+2] %= 10**9 + 7

counter_arr[-1] += counter_arr[-2] * broken_lst[-1]
counter_arr[-1] %= 10**9 + 7

print((counter_arr[-1]))
# Original solution
N, M = list(map(int,input().split()))
data = []
for i in range(M):
    data.append(int(eval(input())))
dp = [0] * (N + 1)
dp[0] = 1
dp[1] = 1
if 1 in data:
    dp[1] = 0
mod = 10**9 + 7
for i in range(2,N + 1):
    if not i in data:
        dp[i] = dp[i - 1] + dp[i - 2]
print((dp[N] % mod))

# Optimized solution
N, M = list(map(int,input().split()))
data = []
dp = ['.' for i in range(N + 1)]
dp[0] = 1
dp[1] = 1
for i in range(M):
    k = int(eval(input()))
    data.append(k)
    dp[k] = 0
mod = 10**9 + 7
for i in range(2,N + 1):
    if dp[i] != 0:
        dp[i] = (dp[i - 1] + dp[i - 2]) % mod
print((dp[N] % mod))
# Original solution
n, m = list(map(int, input().split()))
mod = 10**9 + 7
dp = [0 for i in range(n+1)]
for i in range(m):
    dp[int(eval(input()))] = -1
dp[0] = 1
for i in range(n):
    if dp[i] != -1:
        if dp[i+1] != -1:
            dp[i+1] += dp[i]
            dp[i+1] %= mod
        if i+2 <= n and dp[i+2] != -1:
            dp[i+2] += dp[i]
            dp[i+2] %= mod
print((dp[n]))

# Optimized solution
n, m = list(map(int, input().split()))
dp = [0 for i in range(n + 1)]
mod = 10 ** 9 + 7
broke = set()
for i in range(m):
    broke.add(int(eval(input())))
dp[0] = 1
for i in range(n):
    if i + 1 <= n and i + 1 not in broke:
        dp[i + 1] += dp[i]
        dp[i + 1] %= mod
    if i + 2 <= n and i + 2 not in broke:
        dp[i + 2] += dp[i]
        dp[i + 2] %= mod
print((dp[-1] % mod))
# Original solution
N, B = list(map(int, input().split()))
ana = []
dp = [0] * (N+2)

for i in range(B):
    ana.append(int(eval(input())))

mod = 1000000007

dp[N] = 1
for i in reversed(list(range(N))):
    if i in ana:
        dp[i] = 0
        ana.pop(len(ana)-1)
        continue
    dp[i] = dp[i + 1] + dp[i + 2]
print((dp[0] % mod))

# Optimized solution
N, B = list(map(int, input().split()))
ana = []
dp = [0] * (N+2)

for i in range(B):
    ana.append(int(eval(input())))

mod = 1000000007

dp[N] = 1
for i in reversed(list(range(N))):
    if len(ana) >= 1 and i == ana[-1]:
        dp[i] = 0
        if len(ana) != 0:
            ana.pop(-1)
        continue
    dp[i] = dp[i + 1] + dp[i + 2]
print((dp[0] % mod))
# Original solution
#3問目
NM = input().split()
N,M = int(NM[0]), int(NM[1])
A = []
dp = [0] * (N+1)
dp[0] = 1
dp[1] = 1
MOD = 1000000007
for _ in range(M):
    A.append(int(eval(input())))
    
if(1 in A):
    dp[1] = 0

for i in range(2, N+1):
    #貰うdp
    if(i in A):
        dp[i] = 0
    else:
        dp[i] = dp[i-1] + dp[i-2]
    dp[i] = dp[i] % MOD
    
print((dp[N]))

# Optimized solution
N, M = list(map(int, input().split()))
a = set([int(eval(input())) for _ in range(M)])
INF = 1000000007

dp = [0] * (N + 1)
dp[0] = 1
if 1 not in a:
	dp[1] = 1
else:
	dp[1] = 0
for i in range(2, N + 1):
	if i in a:
		continue
	dp[i] = dp[i - 1] + dp[i - 2]
	dp[i] %= INF

print((dp[N]))
# Original solution
n,m = list(map(int,input().split()))
a = [int(eval(input())) for x in range(m)]
mod = 1000000007
dp = [0] * (n+1)
dp[0] = 1 #0段目へ行く移動方法は1通りしかない
if 1 not in a:#もし階段がぶっ壊れてるリストに1段目が入っていないならば1段目へ行く移動方法は1通り、そうでないなら0通り
    dp[1] = 1
else:
    dp[1] = 0
for i in range(2,n+1):#2段目から調べていく
    if i in a:#現在のi段目がぶっ壊れリストに含まれてるなら何もせず飛ばす
        continue
    dp[i] = dp[i-1] + dp[i-2]#フィボナッチで処理
    dp[i] %= mod#modで割っていく
print((dp[n]))#n+1番目を出力する


# Optimized solution
N, M = list(map(int, input().split()))
a = set([int(eval(input())) for _ in range(M)])
INF = 1000000007

dp = [0] * (N + 1)
dp[0] = 1
if 1 not in a:
	dp[1] = 1
else:
	dp[1] = 0
for i in range(2, N + 1):
	if i in a:
		continue
	dp[i] = dp[i - 1] + dp[i - 2]
	dp[i] %= INF

print((dp[N]))
# Original solution
n,m = list(map(int,input().split()))
a = []
for i in range(m):
    A = int(eval(input()))
    a.append(A)
mod = 1000000007
dp = [0] * (n+1)
dp[0] = 1#0段目へ行く移動方法は1通りしかない
if 1 not in a:#もし階段がぶっ壊れてるリストに1段目が入っていないならば1段目へ行く移動方法は1通り、そうでないなら0通り
    dp[1] = 1
else:
    dp[1] = 0
for i in range(2,n+1):#2段目から調べていく
    if i in a:#現在のi段目がぶっ壊れリストに含まれてるなら何もせず飛ばす
        continue
    dp[i] = dp[i-1] + dp[i-2]#フィボナッチで処理
    dp[i] %= mod#modで割っていく
print((dp[n]))#n+1番目を出力する


# Optimized solution
n,m = list(map(int,input().split()))
a = set([int(eval(input())) for _ in range(m)])
mod = 1000000007
dp = [0] * (n+1)
dp[0] = 1#0段目へ行く移動方法は1通りしかない
if 1 not in a:#もし階段がぶっ壊れてるリストに1段目が入っていないならば1段目へ行く移動方法は1通り、そうでないなら0通り
    dp[1] = 1
else:
    dp[1] = 0
for i in range(2,n+1):#2段目から調べていく
    if i in a:#現在のi段目がぶっ壊れリストに含まれてるなら何もせず飛ばす
        continue
    dp[i] = dp[i-1] + dp[i-2]#フィボナッチで処理
    dp[i] %= mod#modで割っていく
print((dp[n]))#n+1番目を出力する
# Original solution
n, m = list(map(int, input().split()))
a = list(int(eval(input())) for _ in range(m))

for i in range(m-1):
    if m == 1:
        break
    if a[i+1] - a[i] == 1:
        print((0))
        exit()

dp = [0] * (n+1)
dp[0] = 1

if 1 in a:
    dp[1] = 0
else:
    dp[1] = 1

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

print((dp[n]))


# Optimized solution
n, m = list(map(int, input().split()))
a = set([int(eval(input())) for _ in range(m)])

dp = [0] * (n+1)
dp[0] = 1

if 1 in a:
    dp[1] = 0
else:
    dp[1] = 1

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

print((dp[n]))
# Original solution
N, M = list(map(int, input().split()))
a = [int(eval(input()))for i in range(M)]
MOD = 10 ** 9 + 7
ans = []
dp = [1] * N

for i in range(N):
    if (i + 1) in a:
        dp[i] = 0
    elif i == 0:
        dp[i] = 1
    elif i == 1 and dp[0] == 1:
        dp[i] = 2
    elif i == 1 and dp[0] == 0:
        dp[i] = 1
    else:
        dp[i] = (dp[i - 1] + dp[i - 2]) % MOD

print((dp[N-1] % MOD))


# Optimized solution
N, M = list(map(int, input().split()))
a = [int(eval(input()))for i in range(M)]
MOD = 10 ** 9 + 7
ans = []
dp = [1] * (N + 1)

for i in a:
    dp[i] = 0

for i in range(2, N + 1):
    if dp[i] != 0:
        dp[i] = (dp[i - 1] + dp[i - 2])

print((dp[N] % MOD))
# Original solution
N,M = list(map(int, input().split()))
ng = set()
for i in range(M):
  ng.add(int(eval(input())))
  
dp = [0] * (N + 5)
dp[0] = 1

for i in range(N):
  for j in range(1, 3):
    if (i + j) not in ng:
      dp[i + j] += dp[i]
      dp[i + j] %= 1000000007

print((dp[N]))

# Optimized solution
N,M = list(map(int, input().split()))
ng = set()
for i in range(M):
  ng.add(int(eval(input())))
  
dp = [0] * (N + 5)
dp[0] = 1

for i in range(N):
  if i + 1 not in ng:
    dp[i + 1] += dp[i]
    dp[i + 1] %= 1000000007
  if i + 2 not in ng:
    dp[i + 2] += dp[i]
    dp[i + 2] %= 1000000007

print((dp[N]))