Олимпиадный тренинг

Задача 38276. Jackets


Charitable organizations each year raise money for warm clothing for the poor. The protagonist of this task has two jackets, but this does not stop him from suffering. One of his jackets — winter, and the second — demi-season (it's nice to walk in it in autumn or spring). Jackets are matched perfectly: in a winter jacket it is comfortable at a temperature of x degrees or lower, and in a demi-season – at temperatures above x degrees. In general, he would live and be happy. But where would the task come from then?

The problem of our hero is that, putting on the wrong jacket today, which he wore yesterday, he constantly forgets to shift the travel card, keys and other useful things into the pocket of a new jacket. After a little thought, he decided that the jacket, not quite suitable for today's temperature, — it's not as bad as forgotten things. Therefore, if today is slightly warmer than the boundary temperature, he will still go in a winter jacket, similarly for a demi-season one. A little more formally, it sounds like this: he changes his jacket from winter to demi-season only if today there are at least x + d   degrees outside the window, and from demi-season to winter — if outside the window x − d   degrees or colder. Sometimes, of course, he is not very comfortable on the street, but all things are definitely with him.

Based on the weather forecast archive for the last n days, determine how many days the protagonist of this problem was uncomfortable. It is believed that on the first day he went out in the jacket that is comfortable for that day.

Input
The first line contains two real numbers x and d — temperature boundary between jackets and temperature deviation, which the hero of the task considers insignificant (−89≤x≤55, 1≤d≤6 ).

The second line contains an integer n, 1≤n≤105 — number of days in the weather archive.

The third line contains n real numbers ti — temperature on the i-th day (−89≤ti≤55 ).

Imprint
Print a single number: the number of days when the hero of the problem felt uncomfortable in the jacket he wore on that day
 
Examples
# Input Output
1 5 1
7
6 7 4 4 2 3 7
0
2 0 2
4
-1 1 -1 1
2