A Collision Keeps Momentum, and the Restitution Coefficient Sets the Bounce
Two objects collide. The total momentum is always conserved through the collision, and how much they bounce is set by one number, the coefficient of restitution e, from e=1 (perfectly elastic) to e=0 (they stick).
Ball 1 approaches ball 2 at rest. The relative speed at which they close in is the approach speed. Drag v: for an elastic collision of equal masses, the two simply swap velocities.
Even with unequal masses, the total momentum before and after is the same. Drag the mass ratio: the after-velocities change, but the total of the momentum bars stays put (there is no outside force).
The coefficient of restitution e measures the bounce: e = separation speed ÷ approach speed. Drag e and the separation speed becomes e times the approach speed (e=1 bounces back unchanged, e=0 sticks).
Pick a collision type. Perfectly elastic (e=1) even conserves kinetic energy, inelastic (0<e<1) loses some, and perfectly inelastic (e=0) sticks and loses the most. Momentum is conserved in every case.
Drag e to see how much kinetic energy survives. In a head-on collision of equal masses the surviving fraction is (1+e²)2, so e=1 keeps all of it and e=0 keeps only half, the rest scattering into heat, sound, and deformation.