According to law of conservation of momentum we have,

Where,
![m_1=8kg,m_2=16\operatorname{kg},v_(1i)=9\text{ m/s, }v_(2i)=0m/s,v_(1f)=3\text{ m/s}]()
Substituting these values in the above equation,


V2f is what we need to find out
Simplifying the above equation,

which implies

Which gives us

i.e. The velocity of the ball after the collision is 3 m/s