For Ball 1 :
Mass = 0.5 kg
Velocity = 5 m / s
For Ball 2 :
Mass = 1 kg
Velocity = ?
We know that,
Momentum of Ball 1 = Momentum of Ball 2
This can be given by the law of conservation of momentum. Hence we can say that,
Momentum of Ball 1 = Momentum of Ball 2
Momentum of Ball 1 = Mass * Velocity of ball 1
= 0.5 kg * 5 m/s = 2.5 kg.m/s
Momentum of Ball 2 = Mass * Velocity of ball 2
= 1 * v 2.5 kg.m/s = 1 kg * v
=> v = 2.5 kg.m/s / 1 kg = 2.5 m/s
Hence velocity of ball 2 is 2.5 m/s.