#!/usr/bin/env python3
import sys
def fib(n):
a, b = 0, 1
while a<n:
print(a)
a, b = b, a+b
try:
n = int(sys.argv[1])
except IndexError:
raise SystemExit("Please specify a limit. E.g. \"fib.py 13\"")
print("Creating fibonacci sequence limited to: ", n)
fib(n)