Let $a_1,a_2,\ldots,a_K,b_1,b_2,\ldots,b_L$ be positive integers. Prove that $$\frac{(a_1n)!(a_2n)!\cdots (a_Kn)!}{(b_1n)!(b_2n)!\cdots (b_Ln)!} $$ is an integer for all positive integers $n$ if and only if $$\lfloor a_1x \rfloor + \lfloor a_2x \rfloor+ \cdots + \lfloor a_Kx \rfloor \geq \lfloor b_1x \rfloor + \lfloor b_2x \rfloor + \cdots + \lfloor b_Lx \rfloor$$ holds for all positive real $x$.
One direction is easy - compare canonical powers of a prime $p$ in the numerator and denominator and if the inequality is true, set $x = \frac{n}{p^i}$ and sum through all $i$.
But how to prove that if the inequality is false, then there is a $n$ which is a counterexample? Any help appreciated!
Let $c=\max(a_1,...,a_K,b_1,...,b_L)$, and let $P$ be the set of primes $p$ such that $p > c^2$.
Let $W$ be the set of rational numbers of the form ${\Large{\frac{n}{p}}}$, where $p\in P$, and $n$ is a positive integer with $n < p\sqrt{p}$.
First we show that $W$ is dense in $[0,\infty)$.
Let $r,s$ be positive reals with $r < s$, and let $I=(r,s)$.
To show $I\cap W$ is nonempty, choose $p\in P$ with $p > \max\Bigl({\Large{\frac{1}{s-r}}},s^2\Bigr)$.
Let $n$ be a positive integer such that $r < {\Large{\frac{n}{p}}} < s$.
Such a positive integer $n$ exists since from $p > {\Large{\frac{1}{s-r}}}$ we get $s-r > {\Large{\frac{1}{p}}}$,
Thus ${\Large{\frac{n}{p}}}\in I$.
\begin{align*} \text{Then}\;\;& \frac{n}{p} < s \\[4pt] \implies\;& \frac{n^2}{p^2} < s^2 \\[4pt] \implies\;& \frac{n^2}{p^2} < p \\[4pt] \implies\;& n^2 < p^3 \\[4pt] \implies\;& n < p\sqrt{p} \\[4pt] \implies\;& \frac{n}{p}\in W \\[4pt] \end{align*} Thus ${\Large{\frac{n}{p}}}\in I\cap W$, so $I\cap W\ne{\large{\varnothing}}$.
Since $r,s$ are arbitrary positive reals with $r < s$, it follows, as claimed, that $W$ is dense in $[0,\infty)$.
Let $f:(0,\infty)\to\mathbb{R}$ be given by $$ f(x)= \sum_{i=1}^K \lfloor{a_ix}\rfloor - \sum_{j=1}^L \lfloor{b_jx}\rfloor $$
Claim:
If $f(x_0) < 0$ for some positive real number $x_0$, then there is a positive integer $n$ such that the fraction $$ \frac{(a_1n)!\cdots (a_Kn)!}{(b_1n)!\cdots (b_Ln)!} $$ is not an integer.
Proof:
Note that $f$ is right-constant since each summand is right-constant, hence for some $\epsilon > 0$, we have $f(x)=f(x_0)$ for all $x\in[x_0,x_0+\epsilon]$.
By the density of $W$, there exists $w\in W$ such that $f(w)=f(x_0)$, so $f(w) < 0$.
Write $w={\Large{\frac{n}{p}}}$ where $p\in P$ and $n$ is a positive integer such that $n < p\sqrt{p}$. \begin{align*} \text{Then}\;\;& n < p\sqrt{p} \\[4pt] \implies\;& n^2 < p^3 \\[4pt] \implies\;& c^2n^2 < p^4 \\[4pt] \implies\;& cn < p^2 \\[4pt] \implies\;& \left\lfloor{\frac{cn}{p^2}}\right\rfloor=0 \\[4pt] \implies\;& \left\lfloor{\frac{a_in}{p^2}}\right\rfloor=0 \;\;\text{and}\; \left\lfloor{\frac{b_jn}{p^2}}\right\rfloor=0 \;\,\text{for all}\;\, i.j \\[4pt] \implies\;& v_p(a_in!) = \left\lfloor{\frac{a_in}{p}}\right\rfloor \;\,\text{and}\;\, v_p(b_jn!) = \left\lfloor{\frac{b_jn}{p}}\right\rfloor \;\text{for all}\;\, i.j \\[4pt] \implies\;& v_p \left( \frac{(a_1n)!\cdots (a_Kn)!}{(b_1n)!\cdots (b_Ln)!} \right) = f(w) < 0 \\[4pt] \implies\;& \frac{(a_1n)!\cdots (a_Kn)!}{(b_1n)!\cdots (b_Ln)!} \not\in\mathbb{Z} \\[4pt] \end{align*} as was to be shown.