Let $A$ and $B$ be $n\times n$ matrices such that $AB$ is invertible.
Prove that $A$ and $B$ are invertible.
Give an example to show a product of nonsquare matrices can be invertible even though the factors are not.
If $AB$ is invertible, then there exists $(AB)^{-1}$ such that $(AB)(AB)^{-1}=I_n$. So we find inverses for both $A$ and $B$, hence $A$ and $B$ are invertible.
Let $$ A=\begin{pmatrix} 1 & 0 & 0 \\ 0 & 1 & 0 \\ \end{pmatrix} $$ and $$ B=\begin{pmatrix} 1 & 1 \\ 0 & 1 \\ 1 & 0 \\ \end{pmatrix} $$ Then $AB$ is invertible while $A$ and $B$ are not.
Is it fine?