You are viewing a single comment's thread. Return to all comments →
I think this is prettier:
n = int(input()) arr = [0 if i is 0 else i/abs(i) for i in map(int, input().split())] for num in map(arr.count, [1, -1, 0]): print(round(num/n, 6))
Seems like cookies are disabled on this browser, please enable them to open this website
Plus Minus
You are viewing a single comment's thread. Return to all comments →
I think this is prettier: