Canonicalized Input Description:

An integer n (1 ≤ n ≤ 25), representing some quantity. The input ends when n = 0.
Next n lines each contain two integers. The first integer is a non-negative value representing some measure.
The second integer is a positive value representing another measure.

### Example Input:

```
3
2 3
3 6
1 2
3
2 3
3 5
1 2
0
```

### Function Signature:

Write a function f(inputs) that takes in the input.
```python
def f(inputs: List[Tuple[int, List[Tuple[int, int]]]]):
    '''
    inputs: a list of tuples, where each tuple contains an integer and a list of tuples
    '''
```