davea at ieee.org
Tue Sep 28 16:02:27 CEST 2010
On 2:59 PM, Roelof Wobben wrote:
> Im now studying this page :
> But I don't get it why aces are now lower then deuces in the cmp function.
Why would you be surprised that aces are lower than deuces? If aces are
represented by 1, and deuces by 2, then 1 is less than 2.
Notice that because self.suit is compared first, an ace of spades is
higher than a deuce of hearts. It's only within the same suit that an
ace is "less than" a deuce.
More information about the Tutor