n, m = map(int, input().split())
a = [int(input()) for _ in range(m)]
ans = 0

def rec(i, sum):
  if sum == n:
    global ans
    ans += 1
    return False
  elif sum in a:
    return False
  elif sum > n:
    return False
  elif rec(i+1, sum+1):
    return True
  elif rec(i+1, sum+2):
    return True
  else:
    return False

rec(0, 0)
print(ans%1000000007)