Since
we don't make mistakes when we do
physics, we daringly expand the problem to involve a
collision between two entities with different masses (still with only one
dimension).
Before:
o ---> <-- o
mA vA0 vB0 mB
After:
<-- o o --->
vA mA mB vB
Now we get the following:
I) mA * vA + mB * vB = mA * vA0 + mB * vB0 (conservation of momentum)
II) 1/2 * mA * vA2 + 1/2 * mB * vB2 = 1/2 * mA * vA02 + 1/2 * mB * vB02 (phew, conservation of energy)
Note that we can drop the factor 1/2 everywhere by multiplying both sides by two.
Now for an example: You are rolling a bowling ball towards another, lying still. The two collide elastically. The ball you tossed is somewhat heavier than the other. In fact,
mA = 5 kg
vA0 = 30 kph
mB = 3 kg
vB0 = 0 kph
What happens next?
I) vA = (mA * vA0 + mB * vB0 - mB * vB)/mA)
= (150 kg/kph - vB * 3 kg) / 5 kg
= 30 kph - 3/5 * vB
... which may not come as a surprise.
Now insert this in (II), which we leave as an exercise for the clever student, and you get two solutions. Again, one solution is uninteresting - you missed, and the balls continue with their starting velocities. The other solution is (unless I'm completely wrong)
vB = 31.25 kph
vA = 11.25 kph
In general for this example, if the tossed ball is heavier, they both continue in the same direction. If the tossed ball is lighter, it bounces back, giving a smaller speed to the other ball.