You cant slap a battery in and expect "X" number of mph.
It depends on gearing, tire size, tranny ratio, etc.just to make sure you understand, heres a full list of factors.

The esc your using
The car
The gearing
The size of the tires
How your radio is calibrated
Your epa
How much voltage your esc is putting to the motor
The amps being supplied
How much resistance your bearings have
The resistance of wind and the friction of the tires
The temperature
The wind speed and direction
The angle of the road
The force of gravity
The weight
If the chassis is dragging on the ground from it having no suspension
How many wheels are spinning
The weight distribution
But geared right, yes a 2s can go 40.Whether its geared high enough to burn the motor up in one pass, well.Depends on ^^ Those factors.Go 3s and gear down, rather than 2s and gearing up.Better on the motor, less strain on the battery.