"monty" < "python"
R. Michael Weylandt
michael.weylandt at gmail.com
Wed Mar 20 09:40:52 EDT 2013
It's lexigraphic (order by first letter, but if those are the same,
compare the second, but if those are same compare the third, ... if
one ends while the other continues, it's considered 'lower') on the
character's ASCII (binary encoding values):
http://www.asciitable.com/
Note that all the upper case values appear before the lower case
values. (And there are some other 'characters' like newline before
that but you won't see them)
Cheers,
Michael
On Wed, Mar 20, 2013 at 1:33 PM, franzferdinand
<melo.dumoulin at hotmail.com> wrote:
>>>> "Monty" < "Python"
> True
>>>> "Z" < "a"
> True
>>>> "Monty" < "Montague"
>
> False
> What's the rule about that? Is it the number of letters or what?
> thanks
> --
> http://mail.python.org/mailman/listinfo/python-list
More information about the Python-list
mailing list