5. Divide the positive integers $1,2, \cdots, 10$ into two groups:
$$
A=\left\{a_{1}, a_{2}, \cdots, a_{m}\right\}, B=\left\{b_{1}, b_{2}, \cdots, b_{n}\right\} \text {. }
$$

Take one number $a$ from $A$ and one number $b$ from $B$ ($a \in A, b \in B$), divide them to get a number $\frac{a}{b}$, which is called the "quotient" of $a$ and $b$. Then the maximum value of the product of all quotients is $\qquad$ .
5. $\frac{(10!)^{4}}{(4!)^{10}}$.

The product of all quotients is
$$
\begin{array}{l}
S=\prod_{i=1}^{m} \prod_{j=1}^{n} \frac{a_{i}}{b_{j}}=\prod_{i=1}^{m}\left[a_{i}^{n}\left(\prod_{j=1}^{n} b_{j}\right)^{-1}\right] \\
=\left(\prod_{i=1}^{m} a_{i}\right)^{n}\left(\prod_{j=1}^{n} b_{j}\right)^{-m} .
\end{array}
$$

Clearly, to maximize $S$, the larger numbers from 1 to 10 should be in $A$, and the smaller numbers should be in $B$.
$$
\begin{array}{l}
\text { Then } S \leqslant \frac{[10 \times 9 \times \cdots \times(n+1)]^{n}}{[n \times(n-1) \times \cdots \times 1]^{10-n}}: \\
=\frac{(10!)^{n}}{(n!)^{10}}=f(n) . \\
\text { Also } \frac{(10!)^{k+1}}{[(k+1)!]^{0}}>\frac{(10!)^{k}}{(k!)^{10}} \Leftrightarrow 10!>(k+1)^{10},
\end{array}
$$

and $4^{10}f(5)>\cdots>f(10) \text {. }$
$$

Therefore, $S_{\text {max }}=\frac{(10!)^{4}}{(4!)^{10}}$.