On Oct 7, 2012 12:47 PM, "Arnej Duranovic" <arne...@gmail.com> wrote:
>
> When I type this in the python idle shell ( version 3...) :
>             '0' <= '10' <= '9'
> The interpreter evaluates this as true, WHY? 10 is greater than 0 but not
9

Since they are strings it looks at these character by character. Since '0'
< '1' < '9' , the 0 in '10' has no effect on the order.  Compare 'a' < 'ba'
< 'i' .

boB
_______________________________________________
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor

Reply via email to