Code works but doesn't seem to pass
I would like to give some feedback about ...
From: http://www.checkio.org/mission/even-last/solve/
HTTP_USER_AGENT:
Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2490.80 Safari/537.36
def checkio(array): """ sums even-indexes elements and multiply at the last
""" if len(array) == 0: return 0 else: sums = 0 for num in array: if array.index(num) % 2 == 0: sums += num return sums * array[-1]