There are N students standing in a line where each student has some points.

You distribute chocolates to these students under the following constraints:

1. Each student must have at least one chocolate.

2. Students with a higher point value get more chocolates than their neighbors.

Write a method

`distributeChocolate`

to compute the minimum number of chocolates distributed such that the above conditions are satisfied.`distributeChocolate("{1,5,7,1}") ==> 7`

In this example, input is an

`array`

of points which `4`

different students have been allotted. The minimum number of chocolates distributed i.e. the output is `7`

.
Need a **hand?** Try out these hints, one at a time.

public static int distributeChocolate(int[] points) { }

**C**

**Java**

**Python**