An integer N (1 ≤ N ≤ 8), representing some quantity or size.
An integer F (-10^5 ≤ F ≤ 10^5).
An N x N matrix of integers, where each integer is between -10^5 and 10^5.

### Example Input:

```
2 0
1 3
1 1
```

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