A 4 kg ball moving with a velocity of 100m/s collides with a 16 kg ball moving with a velocity of 40m/s. (i) in the same direction, (ii) in the opposite direction. Calculate the velocity of the balls in each case if they coalesce on impact, and the loss of energy resulting from the impact. State the principle used to calculate the velocity.