Skip to content

Instantly share code, notes, and snippets.

@galenseilis
Created October 17, 2022 01:14
Show Gist options
  • Select an option

  • Save galenseilis/3de78682f1627263ce0c4416195403ac to your computer and use it in GitHub Desktop.

Select an option

Save galenseilis/3de78682f1627263ce0c4416195403ac to your computer and use it in GitHub Desktop.
Naive implementation of a 'power tower'.
def exp_seq(iterable):
'''Calculates the exponent tower of a sequence of numbers.'''
a = iterable[0]
for i in iterable[1:]:
a = a**i
return a
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment