Skip to content

Instantly share code, notes, and snippets.

@jtomschroeder
Last active October 6, 2015 03:58
Show Gist options
  • Save jtomschroeder/2932035 to your computer and use it in GitHub Desktop.
Save jtomschroeder/2932035 to your computer and use it in GitHub Desktop.
Fibonacci Python
class Fibonacci:
def __init__(self):
self.x, self.y = 0, 1
def printSeq(self, count):
for i in range(count):
print self.x
self.x, self.y = self.y, self.x + self.y
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment