You can use a generator expression within the sum
function
>>> sum(i**i for i in range(1,11))
10405071317
2
solved How to sum all range output in python 3
You can use a generator expression within the sum
function
>>> sum(i**i for i in range(1,11))
10405071317
2
solved How to sum all range output in python 3