-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtry1.py
More file actions
24 lines (22 loc) · 710 Bytes
/
try1.py
File metadata and controls
24 lines (22 loc) · 710 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
views = [
{'video_genre': 1, 'rating': 7.226},
{'video_genre': 3, 'rating': 2.442},
{'video_genre': 2, 'rating': 8.683},
{'video_genre': 2, 'rating': 9.676},
{'video_genre': 3, 'rating': 4.213},
{'video_genre': 2, 'rating': 3.724},
{'video_genre': 2, 'rating': 5.553},
{'video_genre': 4, 'rating': 9.155},
{'video_genre': 3, 'rating': 4.667},
{'video_genre': 5, 'rating': 5.972},
{'video_genre': 5, 'rating': 6.374},
{'video_genre': 1, 'rating': 3.826},
{'video_genre': 2, 'rating': 1.732},
{'video_genre': 1, 'rating': 7.945},
{'video_genre': 2, 'rating': 1.337},
]
acc = 0
for i in views:
print(i)
acc += i['rating']
print(acc/len(views))