N, M = [int(x) for x in input().split()]
a = set(int(input()) for _ in range(M))

MOD = 10 ** 9 + 7
dp = [0] * (N + 1)
dp[0] = 1

for i in range(1, N + 1):
  if i in a:
    continue
  x = dp[i - 1]
  if i > 1:
    x += dp[i - 2]
  dp[i] = x % MOD

ans = dp[N]
print(ans) int(x) for x in input().split() for x in input().split() x input().split() ().split () input split for x in input().split() int(x) int x N, M = [int(x) for x in input().split()] N [int(x) for x in input().split()] M a = set(int(input()) for _ in range(M)) a set(int(input()) for _ in range(M)) set int(input()) int input() input MOD = 10 ** 9 + 7 MOD 10 ** 9 + 7 10 ** 9 10 9 7 dp = [0] * (N + 1) dp [0] * (N + 1) [0] 0 N + 1 N 1 dp[0] = 1 dp[0] dp 0 1 for i in range(1, N + 1):
  if i in a:
    continue
  x = dp[i - 1]
  if i > 1:
    x += dp[i - 2]
  dp[i] = x % MOD i range(1, N + 1) range 1 N + 1 N 1 if i in a:
    continue
   i in a i a continue x = dp[i - 1] x dp[i - 1] dp i - 1 i 1 if i > 1:
    x += dp[i - 2]
   i > 1 i 1 x += dp[i - 2] x dp[i - 2] dp i - 2 i 2 dp[i] = x % MOD dp[i] dp i x % MOD x MOD ans = dp[N] ans dp[N] dp N print(ans) print ans MOD = 10 ** 9 + 7 10 ** 9 + 7 MOD x = dp[i - 1] dp[i - 1] x ans = dp[N] dp[N] ans a = set(int(input()) for _ in range(M)) set(int(input()) for _ in range(M)) a N, M = [int(x) for x in input().split()] [int(x) for x in input().split()] N M = [int(x) for x in input().split()] [int(x) for x in input().split()] M dp = [0] * (N + 1) [0] * (N + 1) dp x += dp[i - 2] dp[i - 2] x
N, M = [int(x) for x in input().split()]
a = set(int(input()) for _ in range(M))

MOD = 10 ** 9 + 7
dp = [0] * (N + 1)
dp[0] = 1

for i in range(1, N + 1):
  if i in a:
    continue
  x = dp[i - 1]
  if i > 1:
    x += dp[i - 2]
  dp[i] = x % MOD

ans = dp[N]
print(ans)