An integer \(N\) (2 ≤ \(N\) ≤ 10^5), representing some quantity or size.
A list of \(N-1\) tuples \((a_i, b_i)\), where each \(a_i\) and \(b_i\) is an integer (1 ≤ \(a_i, b_i\) ≤ \(N\)).

### Example Input:

```
7
3 6
1 2
3 1
7 4
5 7
1 4
```

### Function Signature:
Write a function `f(N, edges)` that takes in the input.
```python
def f(N: int, edges: List[Tuple[int, int]]):
    ''' 
    N: an integer 
    edges: a list of tuples, each containing two integers
    '''
```