Sumwise

Factorial of 372

372! = 23382183277807774187986718133827188381726286586608758686615142013271552822199766596852702849057571779093790305707083375991131776359200715612479161219636723813165966701093344600305818580527976216963953196978798557986002323087439504449082134541836366758742273637717866678313508154228273169852010483025313255939044328172355506513428529133061201856571138058666882887043338394393524253713946120949755536677481319738966846743141271409133872800102535289431074510986333784338807358545588519000785142251789155972691382857587024725749377714595816241221126619644792735323246345551928980434707617358185422230841473092108912993699930892775187689004120910989110941106125705548826854332519753128809129192869001331029835776000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000

797 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

372! = 372 × 371 × … × 2 × 1 = 2338218327780777418798671813382718838172…

Facts about 372!

Digits797
Trailing zeros90 (one for every factor 5 × 2)
Stirling estimate≈ Infinity
372! ÷ 371!372

Nearby factorials

370!169421378414976771498034… (792 digits)
371!628553313919563822257707… (794 digits)
373!872155436262229977211904… (799 digits)
374!326186133162074011477252… (802 digits)

What are factorials used for?

Counting arrangements: 372! is the number of different orders in which 372 distinct items can be lined up. Factorials also appear in probability, combinations and series.

Counting with 372!

There are 2.3382 × 10^796 different ways to arrange 372 different books on a shelf: 372 choices for the first place, 371 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 372 runners, there are 372 × 371 × 370 = 51,064,440 possible podiums. If the order does not matter, divide by 3! = 6 to get 8,510,740 ways to choose a group of three. Choosing a pair from 372 people can be done in 69,006 ways.

In probability, if 372 names are drawn out of a hat one at a time, the chance of drawing them in one particular order is 1 in 2.3382 × 10^796. That is why shuffled decks and passwords with many symbols are so hard to guess.

How big is 372!?

372! has 797 digits, so it is larger than the estimated number of atoms in the observable universe (about 10^80). The digits add up to 3195, 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 372!

Every prime up to 372 divides 372!. Legendre's formula counts how often: add ⌊n/p⌋ + ⌊n/p²⌋ + ⌊n/p³⌋ + … for each prime p. For 372! that gives 2^367 × 3^183 × 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 372 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 372! ÷ e, so about 36.8% of all 2.3382 × 10^796 orders are derangements. From about four items on, that share stays close to 1 ÷ e, roughly 37%, however many items there are.

Computing 372! yourself

In Excel or Google Sheets, type =FACT(372). 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(372) returns the exact integer with all 797 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.

Calculate another factorial

How answers are calculated and checked: methodology.

Questions

What is 372 factorial?

372! is the product of every whole number from 1 to 372.

How many digits does 372! have?

797. The number of digits of n! is the whole part of log10(n!) plus one.

How many zeros are at the end of 372!?

90. Count the factors of 5 in the numbers 1 to 372: there are always more factors of 2, so every 5 makes one trailing zero.

Is 372! divisible by 373?

No. 373 is prime and bigger than every factor of 372!, so it cannot divide it (Wilson's theorem says 372! leaves a remainder of 372 when divided by 373).

What is the last non-zero digit of 372!?

6. Strip the 90 trailing zeros and look at the digit that is left at the end.

What is 373! in terms of 372!?

373! = 373 × 372!. Each factorial is the previous one multiplied by the next whole number.