Data commit
This commit is contained in:
parent
7387c8f97b
commit
cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions
10
Task/Descending-primes/Perl/descending-primes.pl
Normal file
10
Task/Descending-primes/Perl/descending-primes.pl
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
use strict;
|
||||
use warnings;
|
||||
use ntheory 'is_prime';
|
||||
|
||||
print join( '',
|
||||
sort
|
||||
map { sprintf '%9d', $_ }
|
||||
grep /./ && is_prime $_,
|
||||
glob join '', map "{$_,}", reverse 1..9
|
||||
) =~ s/.{45}\K/\n/gr;
|
||||
Loading…
Add table
Add a link
Reference in a new issue