Ascending primes: Difference between revisions
m
→{{header|Perl}}: code layout
(Nim solution) |
SqrtNegInf (talk | contribs) m (→{{header|Perl}}: code layout) |
||
Line 1,345:
=={{header|Perl}}==
{{libheader|ntheory}}
<syntaxhighlight lang="perl">
use strict;
use warnings;
use ntheory
print join( '',
map { sprintf '%10d', $_ }
grep /./ && is_prime($_),▼
sort { $a <=> $b }
glob join '', map "{$_,}", 1 .. 9) =~ s/.{50}\K/\n/gr;</syntaxhighlight>▼
) =~ s/.{50}\K/\n/gr;
</syntaxhighlight>
{{out}}
<pre>
|