Total momentum is always conserved, in both elastic and inelastic collisions, but total kinetic energy is only conserved in elastic collisions. This example seems to be a completely inelastic collision, because at the end the objects merge. There is a formula to calculate the final velocity $v$ of two object with speed $u_1$ and $u_2$ and mass $m_1$ and $m_2$ in a completely inelastic collision, which is: $$v=\frac{m_1u_1+m_2u_2}{m_1+m_2}$$ Here's a simple derivation:
since momentum is always conserved, the sum of momenta at the beginning is the same as the end: $$p_{i1}+p_{i2}=p_{f1}+p_{f2}$$
However, since this is a completely inelastic collision, at the end the two objects will merge, and so there will be only one final momentum. The final momentum is simply the sum of initial momenta, like final mass is the sum of initial masses: $$p_{1}+p_{2}=p_f\qquad m_1+m_2=m_f$$
Then: $$v=\frac{p_f}{m_f}\qquad v=\frac{p_1+p_2}{m_1+m_2}\qquad v=\frac{m_1u_1+m_2u_2}{m_1+m_2}$$
TheTotal kinetic energy however is not conserved, as you can see summing initial kinetic energies and comparing with the final kinetic energy.