Factorial of 371
371! = 62855331391956382225770747671578463391737329533894512598427801110945034468278942464657803357681644567456425552976030580621321979460216977452900971020528827454747222314767055377166178979913914561731056981125802575231189040557633076476027243392033243975113638811069534081487925145774927875946264739315358214889904107990202974498463787992100004990782629189964738943664888156971839391704156239112246066337315375642383996621347503787994281720705740025352350835984768237469912254154807846776304145838142892399708018434373722381046714286547893121562168332378475094954963294494432743104052734833831780190434067451905680090591212077352655077968066965024491777167004584808674339603547723464540669873303767018897408000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
794 digits
Sumwise · Maintained by Theo Abbott (pen name) · automated checks · Data: exact arithmetic; unit definitions from NIST SP 811 · Updated · How the checks work
How it is calculated
371! = 371 × 370 × … × 2 × 1 = 6285533139195638222577074767157846339173…
Facts about 371!
| Digits | 794 |
|---|---|
| Trailing zeros | 90 (one for every factor 5 × 2) |
| Stirling estimate | ≈ Infinity |
| 371! ÷ 370! | 371 |
Nearby factorials
| 369! | 457895617337775058102795… (789 digits) |
| 370! | 169421378414976771498034… (792 digits) |
| 372! | 233821832778077741879867… (797 digits) |
| 373! | 872155436262229977211904… (799 digits) |
What are factorials used for?
Counting arrangements: 371! is the number of different orders in which 371 distinct items can be lined up. Factorials also appear in probability, combinations and series.
Counting with 371!
There are 6.2855 × 10^793 different ways to arrange 371 different books on a shelf: 371 choices for the first place, 370 for the second, and so on down to one choice for the last. If you only fill the first three places, as with gold, silver and bronze among 371 runners, there are 371 × 370 × 369 = 50,652,630 possible podiums. If the order does not matter, divide by 3! = 6 to get 8,442,105 ways to choose a group of three. Choosing a pair from 371 people can be done in 68,635 ways.
In probability, if 371 names are drawn out of a hat one at a time, the chance of drawing them in one particular order is 1 in 6.2855 × 10^793. That is why shuffled decks and passwords with many symbols are so hard to guess.
How big is 371!?
371! has 794 digits, so it is larger than the estimated number of atoms in the observable universe (about 10^80). The digits add up to 3213, a multiple of 9, as they are for every factorial from 6! on. Stirling's formula, √(2πn) × (n/e)^n, gives a close estimate without multiplying everything out, and gets more accurate as n grows.
Prime factors of 371!
Every prime up to 371 divides 371!. Legendre's formula counts how often: add ⌊n/p⌋ + ⌊n/p²⌋ + ⌊n/p³⌋ + … for each prime p. For 371! that gives 2^365 × 3^182 × 5^90 × 7^61 × 11^36 × 13^30 × 17^22 × 19^20 × 23^16 × 29^12 × … (73 primes in all). The 90 trailing zeros come from pairing the 90 factors of 5 with factors of 2.
Shuffles where nothing stays put
A related count is the number of derangements of 371 items: orders in which no item ends up in its original place, as in a Secret Santa where nobody draws their own name. The count is the whole number nearest to 371! ÷ e, so about 36.8% of all 6.2855 × 10^793 orders are derangements. From about four items on, that share stays close to 1 ÷ e, roughly 37%, however many items there are.
Computing 371! yourself
In Excel or Google Sheets, type =FACT(371). Spreadsheets keep only 15 significant digits, so from 18! on the result is rounded, and FACT stops at 170!, the largest factorial that fits in a standard floating-point number. In Python, math.factorial(371) returns the exact integer with all 794 digits, because Python integers have no size limit. The gamma function extends factorials to fractions: Γ(n + 1) = n!, so (1/2)! = √π ÷ 2 ≈ 0.8862.
Why is 0! equal to 1?
There is exactly one way to arrange nothing, and the rule n! = n × (n − 1)! only works for n = 1 if 0! = 1. Defining it this way keeps formulas for combinations and series correct at the edges.
How answers are calculated and checked: methodology.
Questions
What is 371 factorial?
371! is the product of every whole number from 1 to 371.
How many digits does 371! have?
794. The number of digits of n! is the whole part of log10(n!) plus one.
How many zeros are at the end of 371!?
90. Count the factors of 5 in the numbers 1 to 371: there are always more factors of 2, so every 5 makes one trailing zero.
Is 371! divisible by 372?
Yes. 372 is not prime, so its factors already appear among the numbers 1 to 371.
What is the last non-zero digit of 371!?
8. Strip the 90 trailing zeros and look at the digit that is left at the end.
What is 372! in terms of 371!?
372! = 372 × 371!. Each factorial is the previous one multiplied by the next whole number.