[Purdue-pm] Perl Weekly Challenge hints

Mark Senn mark at purdue.edu
Wed Jul 17 07:22:09 PDT 2019

Why yes---I am trying to get people interested in Perl 6.
You'll thank me in the long run I think.

Perl 6 hints to this week's Perl Weekly Challenge
for this week's weekly challenge

Hints to

multi A(Int $m, Int $n where $m == 0)           { return $n + 1 }
multi A(Int $m, Int $n where $m >  0 && $n > 0) { return A($m-1, A($m,$n-1)) }

say A(1, 2);

Hints to

especially https://docs.perl6.org/language/regexes#Capturing_groups
use ':' (including the quotes) to match a colon literally
use <[a..z]> to match a lowercase letter
https://docs.perl6.org/language/grammars/#Named_Regexes demos named regexes
https://docs.perl6.org/language/regexes#Named_captures demos named captures


More information about the Purdue-pm mailing list