Enable Javascript in your browser and then refresh this page, for a much enhanced experience.
First solution in Clear category for Index Power by han97
def index_power(array, n):
"""
Find Nth power of the element with index N.
"""
try:
return array[n] ** n
except IndexError:
return -1
Aug. 1, 2016
Comments: