Data update
This commit is contained in:
parent
796d366b97
commit
35bcdeebf8
504 changed files with 7045 additions and 610 deletions
18
Task/Summarize-primes/Quackery/summarize-primes.quackery
Normal file
18
Task/Summarize-primes/Quackery/summarize-primes.quackery
Normal file
|
|
@ -0,0 +1,18 @@
|
|||
[ number$
|
||||
space 6 of swap join
|
||||
-7 split nip echo$ ] is rjust ( n --> )
|
||||
|
||||
say " index prime sum" cr
|
||||
say " ----- ----- ---" cr
|
||||
[] 1000 times
|
||||
[ i^ isprime if [ i^ join ] ]
|
||||
0 swap
|
||||
witheach
|
||||
[ dup dip +
|
||||
over isprime iff
|
||||
[ i^ 1+ rjust
|
||||
rjust
|
||||
dup rjust
|
||||
cr ]
|
||||
else drop ]
|
||||
drop
|
||||
Loading…
Add table
Add a link
Reference in a new issue