Python Loop Through An Array Power