Left factorials: Difference between revisions

Content added Content deleted
m (added whitespace before the preamble headers.)
Line 12: Line 12:


<br>This Rosetta Code task will be using this formula for '''left factorial''':
<br>This Rosetta Code task will be using this formula for '''left factorial''':
<big><big>
::: &nbsp; <math> !n = \sum_{k=0}^{n-1} k! </math>
::: &nbsp; <math> !n = \sum_{k=0}^{n-1} k! </math>
</big></big>
where
where
<big><big>
::: &nbsp; <math>!0 = 0</math>
::: &nbsp; <math>!0 = 0</math>
</big></big>


;Task
;Task
Display the left factorials for:
Display the left factorials for:
Line 21: Line 27:
Display the length (in decimal digits) of the left factorials for:
Display the length (in decimal digits) of the left factorials for:
* 1,000, &nbsp; 2,000 &nbsp; through &nbsp; 10,000 &nbsp; (inclusive), by thousands.
* 1,000, &nbsp; 2,000 &nbsp; through &nbsp; 10,000 &nbsp; (inclusive), by thousands.


;Also see
;Also see
* The OEIS entry: [http://oeis.org/A003422 A003422 left factorials]
* The OEIS entry: [http://oeis.org/A003422 A003422 left factorials]
Line 27: Line 35:
* The MathWorld entry: [http://mathworld.wolfram.com/Subfactorial.html subfactorial]
* The MathWorld entry: [http://mathworld.wolfram.com/Subfactorial.html subfactorial]
* The Rosetta Code entry: [http://rosettacode.org/wiki/Permutations/Derangements permutations/derangements (subfactorials)]
* The Rosetta Code entry: [http://rosettacode.org/wiki/Permutations/Derangements permutations/derangements (subfactorials)]
<br><br>




=={{header|Bracmat}}==
=={{header|Bracmat}}==