is a big fan of the popular MOBA League of Legends. He just got off work and plans to play games of LOL. The only problem is that he is afraid of losing streaks. He knows that if he loses too many games in a row, his night will be ruined. Fortunately, by methods only known to him, he knows for each game what is the chance that he will lose it. Given this information, he wants to know what is the expected value of the length of the longest losing streak during those games. The answer should be given modulo .
Input
The first line contains an integer () – the number of games that will play.
The second line contains integers () – the percent probability that will lose the -th game.
Output
You should output one number – the expected value of the length of the longest losing streak modulo .
Example 1
stdin
2
50 50
stdout
1
Example 2
stdin
9
50 3 19 83 24 24 94 26 83
stdout
575309567
Notes
In the first example we have a chance of losing each game. Therefore, we have a chance of losing both games, chance of winning only one game, and of winning both games.
So in the end the answer is .