From 38a2dd0cc58272e1033b7a5c20c040e0e46404d3 Mon Sep 17 00:00:00 2001 From: Rob4t Date: Mon, 22 Apr 2019 14:44:13 +0200 Subject: check if file is readable --- challenge-005/rob4t/perl6/ch-1.p6 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/challenge-005/rob4t/perl6/ch-1.p6 b/challenge-005/rob4t/perl6/ch-1.p6 index 5e12e50898..d4f5295fbe 100644 --- a/challenge-005/rob4t/perl6/ch-1.p6 +++ b/challenge-005/rob4t/perl6/ch-1.p6 @@ -1,7 +1,7 @@ #!/usr/bin/env perl6 use v6; -sub MAIN(Str $word, Str $file = '/usr/share/dict/words') { +sub MAIN(Str $word, Str $file where *.IO.r = '/usr/share/dict/words') { my $word_bag = $word.lc.comb.Bag; my @found_words = $file.IO.lines.grep: { -- cgit