Trouble with max() and __cmp__()

Wojciech Muła wojciech_mula at poczta.null.onet.pl.invalid
Sun Jan 28 16:13:28 EST 2007


Thomas Nelson wrote:
> My code:
>
> class Policy(list):
>     def __cmp__(self,other):
>         return cmp(self.fitness,other.fitness)

Define method __gt__.



More information about the Python-list mailing list