aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLuca Ferrari <fluca1978@gmail.com>2020-04-06 15:19:27 +0200
committerLuca Ferrari <fluca1978@gmail.com>2020-04-06 15:19:27 +0200
commit90604fdd69b2401ecdbf1af514751b23563f6a80 (patch)
tree3fdc02f5b8aafb8c73e65ffa0cffc8c35901d281
parent9ebd18bb5cf6b8c7659bebb2e15d763977157394 (diff)
downloadperlweeklychallenge-club-90604fdd69b2401ecdbf1af514751b23563f6a80.tar.gz
perlweeklychallenge-club-90604fdd69b2401ecdbf1af514751b23563f6a80.tar.bz2
perlweeklychallenge-club-90604fdd69b2401ecdbf1af514751b23563f6a80.zip
Remove pretty printing.
-rw-r--r--challenge-055/luca-ferrari/raku/ch-2.p67
1 files changed, 0 insertions, 7 deletions
diff --git a/challenge-055/luca-ferrari/raku/ch-2.p6 b/challenge-055/luca-ferrari/raku/ch-2.p6
index efa456da41..ab441c61b0 100644
--- a/challenge-055/luca-ferrari/raku/ch-2.p6
+++ b/challenge-055/luca-ferrari/raku/ch-2.p6
@@ -34,19 +34,12 @@ sub MAIN( Int:D $number where { $number.chars > 1 } ){
for @array.permutations -> @current {
my $ok = False;
my $test = True; # true = greater
- my @result;
for 0 ..^ @current.elems - 1 -> $index {
$ok = is-ok @current[ $index ].Int, @current[ $index + 1 ].Int, $test;
$test = ! $test;
- @result.push( @current[ $index ].Str ~ ( $test ?? ' ≥ ' !! ' ≤ ' ) );
last if ! $ok;
}
- if $ok {
- @result.push( @current[ *-1 ].Str ~ ( $test ?? ' ≥ ' !! ' ≤ ' ) );
- say @result;
- }
-
say "Found wave { @current }" if $ok;
}
}