Assuming no external forces acting during the collision, total momentum must be conserved, as follows:
The initial momentum can be expressed as follows (taking as positive the initial direction of the ball):
The final momentum can be expressed as follows (since we know that v'b is opposite to the initial vb):
If we assume that Mc >> mb, we can assume that the car doesn't change its speed at all as a result of the collision, so we can replace V'c by Vc in (3).
So, we can write again (3) as follows:
Replacing (2) and (4) in (1), we get:
Simplifying, and rearranging, we can solve for v'b, as follows:
, which is reasonable, because everything happens as if the ball had hit a wall, and the ball simply had inverted its speed after the collision.