An integer n (2 ≤ n ≤ 10^5), representing some quantity or size.
A list of integers v of size n, where each integer is between 1 and 1e5.

### Example Input:

```
4
3 1 3 2
```

### Function Signature:
Write a function f(n, v) that takes in the input.
def f(n: int, v: List[int]):
    '''
    n: an integer
    v: a list of integers
    '''