N, M = list(map(int,input().split()))
     
b = [0]*(N+2)
b[0] = 1

for i in range(M):
  b[int(input())] = -1
  
for i in range(N):
  if b[i] != -1:
    if b[i+1] != -1:
      b[i+1] += b[i]
      print(b[i])
      print(b[i+1])
      print(b)
    if b[i+2] != -1:
      b[i+2] += b[i]
      print(b)
