#K90847. 100 km Cycling Challenge

    ID: 37843 Type: Default 1000ms 256MiB

100 km Cycling Challenge

100 km Cycling Challenge

You are given several datasets representing the monthly distances cycled by a number of riders. In each dataset, the first number denotes the number of riders. This is followed by that many lines, each containing space‐separated integers representing the distances (in kilometers) a rider cycled over several months.

The task is to count the number of riders in each dataset whose total distance is at least \(100\) kilometers. The input terminates when a dataset starts with a 0.

Note: For a rider with monthly distances \(d_1, d_2, \dots, d_n\), they meet the goal if \(\sum_{i=1}^{n} d_i \geq 100\).

inputFormat

The input consists of multiple datasets. Each dataset begins with an integer \(n\) indicating the number of riders. The following \(n\) lines contain space-separated integers representing the distances cycled by each rider over several months. The input is terminated by a line containing a single 0.

Example:
3
20 30 25 30
10 25 15 20
40 45 10 10
0

outputFormat

For each dataset, output a single integer representing the number of riders who accumulated at least 100 km. Each result should be printed on a new line.

Example Output:
2

## sample
3
20 30 25 30
10 25 15 20
40 45 10 10
0
2

</p>