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 lovelygoo2
Recipients lovelygoo2
Date 2009-09-21.03:03:00
SpamBayes Score 0.00061151345
Marked as misclassified No
Message-id <1253502185.93.0.333528519987.issue6955@psf.upfronthosting.co.za>
In-reply-to
Content
>>> max(['34', '7'])
'7'
>>> #This happens because it is comparing strings.
>>> #I have found a way to fix it though.
>>> def Max(li):
...    greatest=li[0]
...    for item in li:
...        for item2 in li:
...            if int(item)<int(item2) or int(item)<greatest:
...                break
...            else:
...                greatest=int(item)
...    return(greatest)
History
Date User Action Args
2009-09-21 03:03:06lovelygoo2setrecipients: + lovelygoo2
2009-09-21 03:03:05lovelygoo2setmessageid: <1253502185.93.0.333528519987.issue6955@psf.upfronthosting.co.za>
2009-09-21 03:03:03lovelygoo2linkissue6955 messages
2009-09-21 03:03:01lovelygoo2create