We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 00961cf commit 6caa559Copy full SHA for 6caa559
1 file changed
annotator/__main__.py
@@ -400,7 +400,10 @@ def acpl(cpl_list):
400
Average Centipawn Loss
401
Takes a list of integers and returns an average of the list contents
402
"""
403
- return sum(cpl_list) / len(cpl_list)
+ try:
404
+ return sum(cpl_list) / len(cpl_list)
405
+ except ZeroDivisionError:
406
+ return 0
407
408
409
def clean_game(game):
0 commit comments