Set closed under under multiplication

Hello, this is a nice problem.

Suppose $\displaystyle S$ is a set of real numbers, closed under multiplication.

Suppose $\displaystyle S$ is partitioned into $\displaystyle A, B$, such that both $\displaystyle A,B$ are closed under multiplication of *three* elements (so that $\displaystyle a_1,a_2,a_3 \in A$ implies $\displaystyle a_1a_2a_3 \in A$, and similarily for $\displaystyle B$).

Show that either $\displaystyle A$ or $\displaystyle B$ is closed under multiplication.