Data commit
This commit is contained in:
parent
7387c8f97b
commit
cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions
5
Task/Home-primes/Mathematica/home-primes.math
Normal file
5
Task/Home-primes/Mathematica/home-primes.math
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
ClearAll[HP, HPChain]
|
||||
HP[n_] := FromDigits[Catenate[IntegerDigits /@ Sort[Catenate[ConstantArray @@@ FactorInteger[n]]]]]
|
||||
HPChain[n_] := NestWhileList[HP, n, PrimeQ/*Not]
|
||||
Row[Prepend["Home prime chain for " <> ToString[#] <> ": "]@Riffle[HPChain[#], ", "]] & /@ Range[2, 20] // Column
|
||||
Row[Prepend["Home prime chain for 65: "]@Riffle[HPChain[65], ", "]]
|
||||
Loading…
Add table
Add a link
Reference in a new issue