题解 | #记负均正II#记住while True是用来处理输入的
记负均正II
http://www.nowcoder.com/practice/64f6f222499c4c94b338e588592b6a62
num_list = []
while True:
try:
num_list.append(int(input()))
except:
over_list, down_list = [], []
for i in num_list:
if i < 0:
down_list.append(i)
else:
over_list.append(i)
print(len(down_list))
if len(over_list) > 0:
print(round(sum(over_list) /len(over_list), 1))
else:
print(0.0)
break