Length of the sequence#104

Length of the sequence

1 second
64 megabytes
Very easy (≈850)

The input for the program is a sequence of integers that concludes with the number 0. Your task is to determine the length of this sequence, not counting the final zero.

Input:

A sequence of integers, with each number on a separate line.

Output:

A single integer representing the length of the sequence.

Examples

Example 1

Loading
Loading