You run a chemical laboratory which contains **N** beakers containing certain amount of solutions. The i^{th} beaker contains a_{i} ml of a reactant solution. There also **M** chemists waiting outside your laboratory. Each chemist has a parchment of paper which has 3 integers written on it. The i^{th} chemist’s parchment contains 3 integers of the form: **l _{i} r_{i} x_{i}**

It denotes that the i^{th} chemist needs atleast x_{i} ml of reactant solution but you can only take it from the bottles numbered l_{i} to r_{i}. If you are able to meet the i^{th} chemists needs, he is happy .

To put it more succinctly, to make the i^{th} chemist happy, it should be possible to take some beakers from l_{i} to r_{i} such that the sum of their solutions is at least x_{i}.

Print the number of chemists that returned happy after their transaction with you .

Please note that a transaction with one chemist is independent of that with another chemist , that is the the values of the beakers doesn’t change for a new transaction. For each transaction consider that the values to be those that were there initially.

**Input**:

The first line contains 2 integers N and M.

The next line contains N integers, the i^{th} integer denoting a_{i}.

The next M lines are of the form: l_{i} r_{i} x_{i}

**Output**:

Output a single integer: the number of happy chemists.

**Constraints**:

1<=N<= 10^{4}

1<=M<=1000

1<=ai<=10^{4}

1<=l_{i}<=r_{i}<=N

1<=x_{i}<=10^{9}