[docs] [issue31757] Tutorial: Fibonacci numbers start with 1, 1
Heinrich Schnermann
report at bugs.python.org
Wed Oct 11 10:40:20 EDT 2017
New submission from Heinrich Schnermann <pythonbug at schnermann.net>:
In https://docs.python.org/3/tutorial/controlflow.html#defining-functions both examples produce fibonacci numbers starting with 0. They should start with 1, as in the example in https://docs.python.org/3/tutorial/introduction.html#first-steps-towards-programming
The first example should change the lines
while a < n:
print(a, end=' ')
to
while b < n:
print(b, end=' ')
and the second example should change the lines
while a < n:
result.append(a) # see below
to
while b < n:
result.append(b) # see below
----------
assignee: docs at python
components: Documentation
messages: 304144
nosy: docs at python, skyhein
priority: normal
severity: normal
status: open
title: Tutorial: Fibonacci numbers start with 1, 1
type: behavior
versions: Python 3.6
_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue31757>
_______________________________________
More information about the docs
mailing list