An integer n (2 ≤ n ≤ 10^5), representing some quantity or size.
An integer m (2 ≤ m ≤ 10^5), representing some quantity or size.
A list of integers x of size n, where each integer is between -10^9 and 10^9, sorted in ascending order.
A list of integers y of size m, where each integer is between -10^9 and 10^9, sorted in ascending order.

### Example Input:

```
3 3
1 3 4
1 3 6
```

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