Pandigital prime: Difference between revisions
Content added Content deleted
m (→{{header|Quackery}}: added optional pandigital0) |
Thundergnat (talk | contribs) m (→{{header|Raku}}: Slightly more efficient) |
||
Line 560: | Line 560: | ||
=={{header|Raku}}== |
=={{header|Raku}}== |
||
<syntaxhighlight lang="raku" line>for 1, |
<syntaxhighlight lang="raku" line>say ($_..7).reverse.permutations».join.first: &is-prime for 1,0;</syntaxhighlight> |
||
say max ($i..7).map: -> $size { |
|||
|($i..$size).permutations».join.grep(&is-prime); |
|||
} |
|||
}</syntaxhighlight> |
|||
{{out}} |
{{out}} |
||
<pre>7652413 |
<pre>7652413 |