The simple answer to this is that the rubber ball is more 'elastic' than the tennis ball and, assuming they are both dropped from the same height onto the same surface, the tennis ball 'loses' more energy than the rubber ball when it strikes the surface the ball is bouncing off.
Of course no energy is truly ever lost but rather it is transferred or converted into other forms, in this case the energy will be converted into thermal energy (as the balls deform upon striking the surface due to friction within the materials), sound (the noise you hear when the ball strikes the surface) and to varying extents energy is transferred to the surface which the balls are striking.
This energy 'loss' is the reason why the balls do not return to the height the balls were dropped from originally and the amount of energy 'loss' will vary with the type of ball dropped.
Chat with our AI personalities
Rubber will bounce higher than plastic because the rubber has more elastic qualities. A rubber ball will give a little when it hits the floor and a plastic ball will not.