Problem hidden
|This problem was hidden by Editorial Board member probably because it has incorrect language|version or invalid test data, or description of the problem is not clear.|

VSTEPS - Steps

While playing the computer game "Lucky Luke", Bom arrived at a scenario in which Lucky has to climb a staircase consisting of n steps.

The steps are numbered as 1 to n from bottom to top. Lucky may go up one step, or may jump two steps at once. However, some steps are broken and Lucky cannot stand on them. In the beginning, Lucky stands on the first step (the first step is never broken).

Suddenly, Bom arrived at a question: how many ways for Lucky to climb the staircase? (i.e. to stand on the nth step). Bom needs your help to answer this question.

Input

  • The first line consisting of two integers n and k; n is the number of steps in the staircase and k is the number of broken steps (0 ≤ k < n ≤ 100000).
  • The second line consisting of k integers which are the indexes of the broken steps in ascending order.

Output

Print out the remainder of the number of ways for Lucky to climb the staircase when divided to 14062008.

Examples

Input
4 2
2 3

Output
0

Input
90000 1
49000

Output
4108266

Được gửi lên bởi:VOJ Team
Ngày:2008-06-13
Thời gian chạy:1s
Giới hạn mã nguồn:50000B
Memory limit:1536MB
Cluster: Cube (Intel G860)
Ngôn ngữ cho phép:Tất cả ngoại trừ: ERL GOSU JS-RHINO NODEJS PERL6 PYPY RUST SED VB.NET
Nguồn bài:VNOI Marathon '08 - Round 1/DivB
Problem Setter: Ngô Minh Đức

hide comments
2024-10-11 12:05:31
định nghĩa "bậc số 1" của người ra đề lạ nhỉ. nó là bậc chìm vào lòng đất à :v làm mình sai test vd mà ko hiểu sao lại sai
2021-05-27 17:59:44
Tham khảo: https://vnspoj.github.io/problems/VSTEPS
2021-02-21 03:44:08
Thề bài này dễ :v.
Code AC: https://ideone.com/4Tfx09
2020-02-22 15:46:18
một biến thể của bài dãy FIBO :v :v
2019-11-18 12:39:11
1 đấm acc
2019-11-16 14:37:26
dễ vãi
2018-10-06 12:01:29
trường hợp n=1 sai vẫn ac ?? :D ???
2018-09-02 07:02:47
wtf sao test 90000 ko qua mà lại 100đ là sao @@
test yếu à mn
2018-07-09 16:03:23
Dành cho ai bí code :*
http://bit.ly/2Rn9k4z


Last edit: 2019-01-12 01:47:41
2018-01-01 10:21:41
test 90000 1 49000 ko qua nộp ac :v
© Spoj.com. All Rights Reserved. Spoj uses Sphere Engine™ © by Sphere Research Labs.