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: No docs for list comparison
Type: Stage:
Components: Documentation Versions: Python 2.5
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: Nosy List: chaese, georg.brandl, kjohnson, m_n_summerfield
Priority: normal Keywords:

Created on 2007-07-25 15:39 by kjohnson, last changed 2022-04-11 14:56 by admin. This issue is now closed.

Messages (5)
msg32553 - (view) Author: Kent Johnson (kjohnson) * Date: 2007-07-25 15:39
AFAICT there is no documentation for the behaviour of <, > or == for sequences. == is perhaps obvious but it would be worth noting that < and > for lists and strings does a lexicographical comparison on the list elements or string characters.
msg32554 - (view) Author: Carsten Haese (chaese) Date: 2007-07-27 12:29
http://docs.python.org/ref/comparisons.html works for me.
msg32555 - (view) Author: Kent Johnson (kjohnson) * Date: 2007-07-27 12:52
Yes, that is what I was looking for. It seems a strange place for the information. Could this be cross-referenced from the Library Reference? I never even thought to look for it in the Language Ref. Other list operations are documented in 
http://docs.python.org/lib/typesseq.html
and this page discusses comparison of library types in general:
http://docs.python.org/lib/comparisons.html

I think it would be worth either repeating or linking to the information from the language ref on either of these pages.

Thanks,
Kent
msg32556 - (view) Author: Mark Summerfield (m_n_summerfield) Date: 2007-08-03 11:19
I've added a note plus a cross-reference to the comparisons coverage in the language reference.
This won't appear until Python 2.6 though.
msg32557 - (view) Author: Georg Brandl (georg.brandl) * (Python committer) Date: 2007-08-03 11:36
Fixed in rev. 56698.
History
Date User Action Args
2022-04-11 14:56:25adminsetgithub: 45244
2007-07-25 15:39:50kjohnsoncreate