Created
July 30, 2015 16:05
-
-
Save saxbophone/2a7dd699d34f0670b23a to your computer and use it in GitHub Desktop.
Python Sequence theory generator
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| def sequence(i): | |
| store = (i + 1) * (i / 2) | |
| while True: | |
| yield store | |
| store = (store + 1) * (store / 2) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment