Partition an integer x into n primes: Difference between revisions

Content added Content deleted
m (added bullets to the task requirements.)
Line 11: Line 11:


Show in the output section the sum   '''X'''   and the   '''N'''   primes in ascending order separated by plus ('''+''') signs:
Show in the output section the sum   '''X'''   and the   '''N'''   primes in ascending order separated by plus ('''+''') signs:
partition '''99809''' with 1 prime.
<big>&bull;</big> partition '''99809''' with 1 prime.
partition '''18''' with 2 primes.
<big>&bull;</big> partition '''18''' with 2 primes.
partition '''19''' with 3 primes.
<big>&bull;</big> partition '''19''' with 3 primes.
partition '''20''' with 4 primes.
<big>&bull;</big> partition '''20''' with 4 primes.
partition '''2017''' with 24 primes.
<big>&bull;</big> partition '''2017''' with 24 primes.
partition '''22699''' with 1, 2, 3, <u>and</u> 4 primes.
<big>&bull;</big> partition '''22699''' with 1, 2, 3, <u>and</u> 4 primes.
partition '''40355''' with 3 primes.
<big>&bull;</big> partition '''40355''' with 3 primes.


The output could/should be shown in a format such as:
The output could/should be shown in a format such as:


Partitioned 19 with 3 primes: 3+5+11
Partitioned 19 with 3 primes: 3+5+11


::* &nbsp; Use any spacing that may be appropriate for the display.
::* &nbsp; Use any spacing that may be appropriate for the display.