Let $H\trianglelefteq G$, $N\trianglelefteq G$ such that $N\cap H=\{e\}$ and $HN=G$. Then obviously $G=N\rtimes H$, but also $G=N\ltimes H$. This implies $G=N\times H$.
How do I obtain this last implication? At first I have tried constructing an isomorphism $\phi: N\rtimes H\to N\times H, (h,n)\mapsto (h,n)$ but I failed. Then I have tried to construct an isomorphism $\psi: HN\to H\times N, hn\mapsto (h,n)$ but I have faild at that too. For example, I don't see how $\psi(g_1g_2)=\psi(g_1)\psi(g_2)$ unless I know that $G$ is abelian when having the listed properties.