Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
[euler] problem 54 bug fix
  • Loading branch information
andreoss committed Jun 23, 2015
1 parent 3d47aed commit 3ba4aa9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions categories/euler/prob054-andreoss.pl
Expand Up @@ -20,7 +20,7 @@
=end pod

enum Rank <
Two Three Four
Two Three Four Five
Six Seven Eight Nine
Ten Jack Queen King Ace
>;
Expand Down Expand Up @@ -201,7 +201,7 @@
for Hand.enums.sort(*.value).keys.map({Hand($_)}) -> $h {
return More if $a.score{$h}.defined && !$b.score{$h}.defined;
return Less if $b.score{$h}.defined && !$a.score{$h}.defined;
next unless $a.score{$h} & $b.score{$h};
next unless $a.score{$h}.defined & $b.score{$h}.defined;

if $a.score{$h} & $b.score{$h} ~~ List {
my $cmp = max $a.score{$h} Z<=> $b.score{$h};
Expand Down

0 comments on commit 3ba4aa9

Please sign in to comment.