if
a, b = 0, 1
means
a = 0
b = 1
then
a, b = b , a + b
should be
a = b
b = a + b
but if I use that in fib function at (https://docs.python.org/3/tutorial/controlflow.html#defining-functions) it does not work. can some one help me understand how it work ?
so output of
def fib(n):
a, b = 0, 1
while a < n:
print(a, end = ' ')
a = b
b = a + b
print()
fib(50)
is 0 1 2 4 8 16 32