6.7. While: Average of sequence
Given a sequence of non-negative integers, where each number is written in a separate line. The sequence ends with 0. Print the average of the sequence.
Example input
10
30
0
Example output
20.0
Given a sequence of non-negative integers, where each number is written in a separate line. The sequence ends with 0. Print the average of the sequence.
Example input
10
30
0
Example output
20.0