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.

Author lucassdssampaio
Recipients lucassdssampaio, mark.dickinson, tim.peters
Date 2018-07-01.21:12:20
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <CAC-4VvM5_4z+G0QvqJHhb8L76svPS2f=26Qhaf9VqZ7V1maC9g@mail.gmail.com>
In-reply-to <1530479109.2.0.56676864532.issue34016@psf.upfronthosting.co.za>
Content
ok, I got it

lista4 = input().split()
print(lista4)
lista4.sort()
print(lista4)

print(type(lista4[2]))

 6 8 10['6', '8', '10']
['10', '6', '8']
<class 'str'>

ok, I got it

2018-07-01 18:05 GMT-03:00 Tim Peters <report@bugs.python.org>:

>
> Tim Peters <tim@python.org> added the comment:
>
> Lucas, as Mark said you're sorting _strings_ here, not sorting integers.
> Please study his reply.  As strings, "10" is less than "9", because "1" is
> less than "9".
>
> >>> "10" < "9"
> True
> >>> 10 < 9
> False
>
> ----------
> nosy: +tim.peters
>
> _______________________________________
> Python tracker <report@bugs.python.org>
> <https://bugs.python.org/issue34016>
> _______________________________________
>
History
Date User Action Args
2018-07-01 21:12:21lucassdssampaiosetrecipients: + lucassdssampaio, tim.peters, mark.dickinson
2018-07-01 21:12:20lucassdssampaiolinkissue34016 messages
2018-07-01 21:12:20lucassdssampaiocreate