This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: Might be a wrong implementation
Type: behavior Stage: resolved
Components: Documentation Versions: Python 3.5
process
Status: closed Resolution: not a bug
Dependencies: Superseder:
Assigned To: docs@python Nosy List: Sai Bhargava Ramu, docs@python, serhiy.storchaka
Priority: normal Keywords:

Created on 2017-11-19 09:08 by Sai Bhargava Ramu, last changed 2022-04-11 14:58 by admin. This issue is now closed.

Files
File name Uploaded Description Edit
combinations.py Sai Bhargava Ramu, 2017-11-19 09:08
Messages (2)
msg306499 - (view) Author: Sai Bhargava Ramu (Sai Bhargava Ramu) Date: 2017-11-19 09:08
https://docs.python.org/2/library/itertools.html#itertools.combinations

#The behaviour of combinations function in documentation is different and I think identation is missing with `else`
#I didn't get the logic right is point out anything further. This might not be a real issue
msg306500 - (view) Author: Serhiy Storchaka (serhiy.storchaka) * (Python committer) Date: 2017-11-19 09:27
The implementation in the documentation is correct. Did you tested your implementation?

The indentation of the "else" is correct. See https://docs.python.org/3/reference/compound_stmts.html#the-for-statement
History
Date User Action Args
2022-04-11 14:58:54adminsetgithub: 76255
2017-11-19 09:27:44serhiy.storchakasetstatus: open -> closed

nosy: + serhiy.storchaka
messages: + msg306500

resolution: not a bug
stage: resolved
2017-11-19 09:08:49Sai Bhargava Ramucreate